stanley-king 2 rokov pred
rodič
commit
78f2738cae

+ 3 - 2
core/framework/function/core.php

@@ -483,7 +483,7 @@ function Model($model = null, $base_path = null)
         $class_name = $model.'Model';
 
         if (!file_exists($file_name)){
-            return $_cache[$cache_key] =  new Model($model);
+            $_cache[$cache_key] =  new Model($model);
         }
         else
         {
@@ -492,9 +492,10 @@ function Model($model = null, $base_path = null)
                 $error = 'Model Error:  Class '.$class_name.' is not exists!';
                 throw_exception($error);
             }else{
-                return $_cache[$cache_key] = new $class_name();
+                $_cache[$cache_key] = new $class_name();
             }
         }
+        return $_cache[$cache_key];
     }
 }
 

+ 1 - 1
docker/compose/workcuda/slave-crond/docker-compose.yml

@@ -42,4 +42,4 @@ services:
       - /mnt/upload:/var/www/html/data/upload
       - /mnt/shoplog:/var/www/html/data/log
     container_name: "panda-statutil"
-    command: [php,"/var/www/html/crontab/index.php",'minutes','stat_util']
+    command: [php,"/var/www/html/crontab/index.php",'minutes','stat_util']