Kaynağa Gözat

bugfix configoptions

andre 1 yıl önce
ebeveyn
işleme
1cdbcc5eff

+ 9 - 6
core/App/Controllers/Instances/AddonController.php

@@ -105,12 +105,15 @@ abstract class AddonController implements DefaultController
      */
     public function isValidIntegrationCallback($callback = null)
     {
-        if (is_callable($callback))
-        {
-            return true;
-        }
-
-        return false;
+        if(!is_array($callback))
+            {
+                return false;
+            }
+        $callback = array_reverse($callback);
+        $class = array_pop($callback);
+        $method = array_pop($callback);
+         
+        return is_string($class) &&  is_string($method) && method_exists($class, $method);
     }
 
     /**