1
0
mirror of https://github.com/spl0k/supysonic.git synced 2024-11-10 04:02:17 +00:00

Return a correct error when the client parameter isn't supplied

This commit is contained in:
spl0k 2017-10-16 19:57:09 +02:00
parent 534a6de4a0
commit 4d3809a835

View File

@ -81,6 +81,9 @@ def get_client_prefs():
if not request.path.startswith('/rest/'):
return
if 'c' not in request.values:
return request.error_formatter(10, 'Missing required parameter')
client = request.values.get('c')
prefs = store.get(ClientPrefs, (request.user.id, client))
if not prefs: