diff --git a/app/Repositories/TrackerRepository.php b/app/Repositories/TrackerRepository.php index 5a6f1b16..dc8f0579 100644 --- a/app/Repositories/TrackerRepository.php +++ b/app/Repositories/TrackerRepository.php @@ -680,7 +680,7 @@ class TrackerRepository extends BaseRepository $log .= "[SP_STATE_REAL]: $spStateReal"; $promotionInfo = apply_filter('torrent_promotion', $torrent->toArray()); do_log("promotionInfo from filter torrent_promotion by torrent: " . $torrent->id . ", get : " . json_encode($promotionInfo)); - if ($promotionInfo['sp_state'] != $spStateReal) { + if (isset($promotionInfo['__ignore_global_sp_state']) && $promotionInfo['sp_state'] != $spStateReal) { $spStateReal = $promotionInfo['sp_state']; $log .= "[CHANGE_SP_STATE_REAL_BY_FILTER_TORRENT_PROMOTION]: $spStateReal"; } diff --git a/include/constants.php b/include/constants.php index 1078dd67..3e2c053e 100644 --- a/include/constants.php +++ b/include/constants.php @@ -1,6 +1,6 @@ get_value('category_content')){ + if (!$rows && !$rows = (array)$Cache->get_value('category_content')){ $res = sql_query("SELECT categories.*, searchbox.name AS catmodename FROM categories LEFT JOIN searchbox ON categories.mode=searchbox.id"); while($row = mysql_fetch_array($res)) { $rows[$row['id']] = $row; diff --git a/nexus/Database/NexusDB.php b/nexus/Database/NexusDB.php index d2c7635f..248631b1 100644 --- a/nexus/Database/NexusDB.php +++ b/nexus/Database/NexusDB.php @@ -290,7 +290,7 @@ class NexusDB public static function table($table): \Illuminate\Database\Query\Builder { if (IN_NEXUS) { - return Capsule::table($table); + return Capsule::table($table, null, self::ELOQUENT_CONNECTION_NAME); } return DB::table($table); }