mirror of
https://github.com/spl0k/supysonic.git
synced 2024-12-22 17:06:17 +00:00
Return a correct error when the client parameter isn't supplied
This commit is contained in:
parent
534a6de4a0
commit
4d3809a835
@ -81,6 +81,9 @@ def get_client_prefs():
|
|||||||
if not request.path.startswith('/rest/'):
|
if not request.path.startswith('/rest/'):
|
||||||
return
|
return
|
||||||
|
|
||||||
|
if 'c' not in request.values:
|
||||||
|
return request.error_formatter(10, 'Missing required parameter')
|
||||||
|
|
||||||
client = request.values.get('c')
|
client = request.values.get('c')
|
||||||
prefs = store.get(ClientPrefs, (request.user.id, client))
|
prefs = store.get(ClientPrefs, (request.user.id, client))
|
||||||
if not prefs:
|
if not prefs:
|
||||||
|
Loading…
Reference in New Issue
Block a user