Skip to content

Commit

Permalink
BcBaserHelper::getContentsMenu() / BcBaserHelper::getGlobalMenu() のキャ…
Browse files Browse the repository at this point in the history
…ッシュを無効化する処理が失敗していたので調整
  • Loading branch information
ryuring committed Apr 29, 2018
1 parent 13232bc commit 8eec86b
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions lib/Baser/View/Helper/BcBaserHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -1676,10 +1676,11 @@ public function getContentsMenu($id = null, $level = null, $currentId = null, $o
}
$options = array_merge([
'tree' => $this->BcContents->getTree($id, $level),
'currentId' => $currentId
'currentId' => $currentId,
'cache' => false
], $options);
$options['tree'] = $this->_unsetIndexInContentsMenu($options['tree']);
if (empty($_SESSION['Auth'][Configure::read('BcAuthPrefix.admin.sessionKey')]) && $options['cache'] === false) {
if (empty($_SESSION['Auth'][Configure::read('BcAuthPrefix.admin.sessionKey')]) && $options['cache'] !== false) {
$options = array_merge($options, [
'cache' => [
'time' => Configure::read('BcCache.duration'),
Expand Down Expand Up @@ -1748,9 +1749,10 @@ public function getGlobalMenu($level = 1, $options = []) {
$options = array_merge([
'tree' => $this->BcContents->getTree($id, $level),
'currentId' => $currentId,
'data' => []
'data' => [],
'cache' => true
], $options);
if (empty($_SESSION['Auth'][Configure::read('BcAuthPrefix.admin.sessionKey')]) && $options['cache'] === false) {
if (empty($_SESSION['Auth'][Configure::read('BcAuthPrefix.admin.sessionKey')]) && $options['cache'] !== false) {
$options = array_merge($options, [
'cache' => [
'time' => Configure::read('BcCache.duration'),
Expand Down

0 comments on commit 8eec86b

Please sign in to comment.