feat: allow deleting of smart playlists.
This commit is contained in:
parent
f3a6b4a225
commit
7a590ade7e
2 changed files with 16 additions and 0 deletions
|
@ -58,5 +58,13 @@ namespace Jellyfin.Plugin.SmartPlaylist.Api {
|
|||
await _store.SaveSmartCollectionAsync(smartCollection);
|
||||
return Created();
|
||||
}
|
||||
|
||||
[HttpDelete]
|
||||
[Route("{smartCollectionId}")]
|
||||
[ProducesResponseType(StatusCodes.Status204NoContent)]
|
||||
public async Task<ActionResult> DeleteCollection([FromRoute, Required] SmartCollectionId smartCollectionId) {
|
||||
_store.DeleteSmartCollectionById(smartCollectionId);
|
||||
return NoContent();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -57,5 +57,13 @@ namespace Jellyfin.Plugin.SmartPlaylist.Api {
|
|||
await _store.SaveSmartPlaylistAsync(smartPlaylist);
|
||||
return Created();
|
||||
}
|
||||
|
||||
[HttpDelete]
|
||||
[Route("{smartPlaylistId}")]
|
||||
[ProducesResponseType(StatusCodes.Status204NoContent)]
|
||||
public async Task<ActionResult> DeletePlaylist([FromRoute, Required] SmartPlaylistId smartPlaylistId) {
|
||||
_store.DeleteSmartPlaylistById(smartPlaylistId);
|
||||
return NoContent();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue