stanley-king 3 tahun lalu
induk
melakukan
1378da3e5b
2 mengubah file dengan 2 tambahan dan 4 penghapusan
  1. 2 2
      core/framework/libraries/model.php
  2. 0 2
      crontab/index.php

+ 2 - 2
core/framework/libraries/model.php

@@ -780,7 +780,7 @@ class ModelDb
         if(is_mobile())
         {
             $sql = $this->buildSelectSql($options);
-            $result = DB::getAll($sql,($options['lock'] === true || $options['master'] === true || defined('TRANS_MASTER')) ? 'master' : 'slave');
+            $result = DB::getAll($sql,($options['lock'] === true || $options['master'] === true) ? 'master' : 'slave');
             return $result;
         }
         else
@@ -794,7 +794,7 @@ class ModelDb
                     return $_cache[$key];
                 }
             }
-            $result = DB::getAll($sql, ($options['lock'] === true || $options['master'] === true || defined('TRANS_MASTER')) ? 'master' : 'slave');
+            $result = DB::getAll($sql, ($options['lock'] === true || $options['master'] === true) ? 'master' : 'slave');
             if ($options['cache'] === true && !isset($_cache[$key])) {
                 $_cache[$key] = $result;
             }

+ 0 - 2
crontab/index.php

@@ -15,8 +15,6 @@ require_once(BASE_ROOT_PATH . '/helper/img_helper.php');
 require_once(BASE_ROOT_PATH . '/helper/exceptionex.php');
 require_once(BASE_ROOT_PATH . '/helper/notify_helper.php');
 
-define('TRANS_MASTER',true);
-
 if (php_sapi_name() == 'cli') {
     $_GET['act'] = $_SERVER['argv'][1];
     $_GET['op'] = empty($_SERVER['argv'][2]) ? 'index' : $_SERVER['argv'][2];