]> kaliko git repositories - mpd-sima.git/commitdiff
Use window option in find request
authorkaliko <kaliko@azylum.org>
Wed, 16 Dec 2020 13:05:29 +0000 (14:05 +0100)
committerkaliko <kaliko@azylum.org>
Wed, 16 Dec 2020 13:05:33 +0000 (14:05 +0100)
Limit response size since this is only to test filter validity, response
is useless anyway.

sima/plugins/internal/tags.py

index 5ea4726837d2462917fd0c4c028e418b5d13e775..9a931fcaecf40deebbe454fcdfee7a7612a4ed54 100644 (file)
@@ -112,7 +112,8 @@ class Tags(Plugin):
         # Check filter is valid
         try:
             if self.plugin_conf['filter']:
-                self.player.find(self.plugin_conf['filter'])
+                # Use window to limit response size
+                self.player.find(self.plugin_conf['filter'], "window", (0, 1))
         except CommandError:
             raise PluginException('Badly formated filter in tags plugin configuration: "%s"'
                                   % self.plugin_conf['filter'])