Skip to content

Commit 4cecb22

Browse files
authored
Handle 'None' uri or empty string uri in transfer command (#1439)
1 parent 7003e98 commit 4cecb22

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3333
- [connect] Fix "play" command not handled if missing "offset" property
3434
- [discovery] Fix libmdns zerconf setup errors not propagating to the main task.
3535
- [metadata] `Show::trailer_uri` is now optional since it isn't always present (breaking)
36+
- [connect] Handle transfer of playback with empty "uri" field
3637

3738
### Removed
3839

connect/src/state/context.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ impl ConnectState {
342342
Err(StateError::InvalidTrackUri(Some(uri.clone())))?
343343
}
344344
(Some(uri), _) if !uri.is_empty() => SpotifyId::from_uri(uri)?,
345-
(None, Some(gid)) if !gid.is_empty() => SpotifyId::from_raw(gid)?,
345+
(_, Some(gid)) if !gid.is_empty() => SpotifyId::from_raw(gid)?,
346346
_ => Err(StateError::InvalidTrackUri(None))?,
347347
};
348348

0 commit comments

Comments
 (0)