aboutsummaryrefslogtreecommitdiff
path: root/src/util/mod.rs
diff options
context:
space:
mode:
authorNathan Perry <np@nathanperry.dev>2024-08-16 01:46:17 -0400
committerNathan Perry <np@nathanperry.dev>2024-08-16 01:46:17 -0400
commitf39b1607b54073646b8ebae8852000706db885ad (patch)
tree8033b4460593fb729f6aecc1c7deba84d952f3f0 /src/util/mod.rs
parenta435a926689b0b597caa1c724a91694f74dec778 (diff)
fix required command options
Diffstat (limited to 'src/util/mod.rs')
-rw-r--r--src/util/mod.rs11
1 files changed, 1 insertions, 10 deletions
diff --git a/src/util/mod.rs b/src/util/mod.rs
index f959a37..5b943fe 100644
--- a/src/util/mod.rs
+++ b/src/util/mod.rs
@@ -176,15 +176,6 @@ pub async fn ytdl_url(uri: &str) -> anyhow::Result<String> {
use serde_json::Value;
use tokio::process::Command;
- lazy_static! {
- static ref YTDL_COMMAND: String = {
- let result = CONFIG.ytdl.clone().unwrap_or("youtube-dl".to_owned());
- debug!("got ytdl: {}", result);
-
- result
- };
- }
-
let args = [
"-f",
"webm[abr>0]/bestaudio/best",
@@ -196,7 +187,7 @@ pub async fn ytdl_url(uri: &str) -> anyhow::Result<String> {
debug!("downloading info for uri: {uri}");
- let mut command = Command::new(&*YTDL_COMMAND);
+ let mut command = Command::new(&*crate::config::YTDL_COMMAND);
command.args(args).stdin(Stdio::null());
debug!("running command: {command:?}");