Skip to content

Commit

Permalink
fix baserproject#3545 メインサイトでブログのエイリアスを作成すると、Blog->Posts()で呼び出された記事のU…
Browse files Browse the repository at this point in the history
…RLがすべて1つ目のエイリアスのURLになってしまう問題を解決
  • Loading branch information
kato committed Jun 24, 2024
1 parent e4e9d36 commit 31e72d0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/bc-blog/src/View/Helper/BlogHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ public function setContent($blogContentId = null)
// 現在のサイトにエイリアスが存在するのであればそちらを優先する
$site = $this->_View->getRequest()->getAttribute('currentSite');
$content = null;
if (!empty($site->id)) {
if (!empty($site->id) && $site->id > 1) {
$content = $contentTable->find()->where([
'Contents.entity_id' => $this->currentBlogContent->id,
'Contents.type' => 'BlogContent',
Expand Down

0 comments on commit 31e72d0

Please sign in to comment.