diff --git a/supysonic/api/extensions.py b/supysonic/api/extensions.py index 4b1f505..ee2c307 100644 --- a/supysonic/api/extensions.py +++ b/supysonic/api/extensions.py @@ -13,4 +13,5 @@ from . import api_routing @api_routing("/getOpenSubsonicExtensions") def extensions(): - return request.formatter("openSubsonicExtensions", []) + extensions = [{"name": "formPost", "versions": [1]}] + return request.formatter("openSubsonicExtensions", extensions) diff --git a/supysonic/api/formatters.py b/supysonic/api/formatters.py index 7ac5073..5d90609 100644 --- a/supysonic/api/formatters.py +++ b/supysonic/api/formatters.py @@ -32,7 +32,7 @@ class BaseFormatter: class JSONBaseFormatter(BaseFormatter): def __remove_empty_lists(self, d): if not isinstance(d, dict): - raise TypeError("Expecting a dict got " + type(d).__name__) + return d keys_to_remove = [] for key, value in d.items():