From f243ac870340015ba681fe3af2266efea822093c Mon Sep 17 00:00:00 2001 From: maikirakiwi Date: Sun, 10 Jul 2022 04:24:19 -0700 Subject: [PATCH] I blame that I suck --- Cargo.toml | 2 +- package.json | 2 +- src/lib.rs | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index ea8a853..ceb11b0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "cider_utils" -version = "0.1.4" +version = "0.1.5" license = "AGPL-3.0" edition = "2021" exclude = ["index.node"] diff --git a/package.json b/package.json index de040bf..6d24f3e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "cider_utils", - "version": "0.1.4", + "version": "0.1.5", "description": "", "main": "index.js", "files": [ diff --git a/src/lib.rs b/src/lib.rs index 54743fb..bed3d01 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -42,8 +42,8 @@ pub fn recursive_folder_search(mut cx: FunctionContext) -> JsResult { let file_name_ascii_lowercase = file.file_name().to_ascii_lowercase(); let file_ext_str = file_extension_parser(file_name_ascii_lowercase.to_str().unwrap()); match file_ext_str { - Some("mp3" | "flac" | "wav" | "opus") => parse_file_vec.push(file.file_name().to_str().unwrap().to_owned()), - Some("aac" | "m4a" | "ogg" | "webm") => music_metadata_vec.push(file.file_name().to_str().unwrap().to_owned()), + Some("mp3" | "flac" | "wav" | "opus") => parse_file_vec.push(file.path().as_os_str().to_str().unwrap().to_owned()), + Some("aac" | "m4a" | "ogg" | "webm") => music_metadata_vec.push(file.path().as_os_str().to_str().unwrap().to_owned()), _ => continue, }; }