Added icarus_envy #140
@@ -508,7 +508,7 @@ pub mod endpoint {
|
||||
let song_id = payload.song_id;
|
||||
match crate::callers::song::song_db::get_song(&pool, &song_id).await {
|
||||
Ok(song) => {
|
||||
let directory = crate::environment::get_root_directory().await.unwrap();
|
||||
let directory = icarus_envy::environment::get_root_directory().await;
|
||||
let dir = std::path::Path::new(&directory);
|
||||
|
||||
// TODO: Make this random and the file extension should not be hard coded
|
||||
|
||||
+1
-1
@@ -770,7 +770,7 @@ pub mod endpoint {
|
||||
let mut song = payload.to_song();
|
||||
song.filename =
|
||||
song.generate_filename(icarus_models::types::MusicTypes::FlacExtension, true);
|
||||
song.directory = crate::environment::get_root_directory().await.unwrap();
|
||||
song.directory = icarus_envy::environment::get_root_directory().await;
|
||||
|
||||
match song_queue::get_data(&pool, &payload.song_queue_id).await {
|
||||
Ok(data) => {
|
||||
|
||||
+1
-1
@@ -9,7 +9,7 @@ pub mod db {
|
||||
}
|
||||
|
||||
pub async fn create_pool() -> Result<sqlx::PgPool, sqlx::Error> {
|
||||
let database_url = crate::environment::get_db_url().await;
|
||||
let database_url = icarus_envy::environment::get_db_url().await;
|
||||
println!("Database url: {:?}", database_url);
|
||||
|
||||
PgPoolOptions::new()
|
||||
|
||||
Reference in New Issue
Block a user