Skip to content

Commit 776a458

Browse files
committed
chore: Improve logging while loading local files
1 parent 33a8b77 commit 776a458

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

playback/src/player.rs

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1212,18 +1212,15 @@ impl PlayerTrackLoader {
12121212
track_uri: SpotifyUri,
12131213
position_ms: u32,
12141214
) -> Option<PlayerLoadedTrackData> {
1215+
info!("Loading local file with Spotify URI <{}>", track_uri);
1216+
12151217
let entry = self.local_file_lookup.get(&track_uri);
12161218

12171219
let Some(path) = entry else {
12181220
error!("Unable to find file path for local file <{track_uri}>");
12191221
return None;
12201222
};
12211223

1222-
debug!(
1223-
"Located file path '{}' for local file <{track_uri}>",
1224-
path.display()
1225-
);
1226-
12271224
let src = match File::open(path) {
12281225
Ok(src) => src,
12291226
Err(e) => {
@@ -1277,6 +1274,12 @@ impl PlayerTrackLoader {
12771274
}
12781275
};
12791276

1277+
info!(
1278+
"Loaded <{}> from path <{}>",
1279+
local_file_metadata.name,
1280+
path.display()
1281+
);
1282+
12801283
Some(PlayerLoadedTrackData {
12811284
decoder,
12821285
normalisation_data,

0 commit comments

Comments
 (0)