Display a more informative message when attempting media op without folder
This commit is contained in:
parent
19b08eb280
commit
cff613bfef
@ -43,6 +43,9 @@ impl MediaManager {
|
||||
P2: AsRef<Path>,
|
||||
{
|
||||
let media_folder = media_folder.into();
|
||||
if media_folder.as_os_str().is_empty() {
|
||||
invalid_input!("attempted media operation without media folder set");
|
||||
}
|
||||
create_dir_all(&media_folder)?;
|
||||
Ok(MediaManager {
|
||||
db: MediaDatabase::new(media_db.as_ref())?,
|
||||
|
Loading…
Reference in New Issue
Block a user