feat: create new empty playlist via command (#272)
* feat: create new empty playlist via command - type :newplaylist <name> to create a new playlist fixes #242 * use full argument string for playlist name Co-authored-by: Henrik Friedrichsen <henrik@affekt.org>
This commit is contained in:
@@ -184,6 +184,13 @@ impl CommandManager {
|
||||
self.register_keybindings(s);
|
||||
Ok(None)
|
||||
}
|
||||
Command::NewPlaylist(name) => {
|
||||
match self.spotify.create_playlist(name, None, None) {
|
||||
Some(_) => self.library.update_library(),
|
||||
None => error!("could not create playlist {}", name),
|
||||
}
|
||||
Ok(None)
|
||||
}
|
||||
Command::Search(_)
|
||||
| Command::Jump(_)
|
||||
| Command::Move(_, _)
|
||||
|
||||
Reference in New Issue
Block a user