]> git.wh0rd.org - tt-rss.git/commitdiff
add additional check for sphinxclient class
authorAndrew Dolgov <noreply@fakecake.org>
Fri, 3 Apr 2015 16:53:35 +0000 (19:53 +0300)
committerAndrew Dolgov <noreply@fakecake.org>
Fri, 3 Apr 2015 16:53:35 +0000 (19:53 +0300)
plugins/search_sphinx/init.php

index 557b2682cad0bb56dfc87218a7ada6183bbaa23e..065af64f2ae08ac68d5e1f9100db023dc4ad3199 100644 (file)
@@ -11,7 +11,8 @@ class Search_Sphinx extends Plugin {
        function init($host) {
                $host->add_hook($host::HOOK_SEARCH, $this);
 
-               if (class_exists("SphinxClient")) {
+               // idk if that would work but checking for the class being loaded is somehow not enough
+               if (class_exists("SphinxClient") && !defined('SEARCHD_COMMAND_SEARCH')) {
                        user_error("Your PHP has a separate systemwide Sphinx client installed which conflicts with the client library used by tt-rss. Either remove the system library or disable Sphinx support.");
                }