@@ -121,8 +121,9 @@ |
||
| 121 | 121 | ->first(); |
| 122 | 122 | |
| 123 | 123 | // Abort if there is no source, or it has no tags |
| 124 | - if (!$post || (!$tagIds = $post->tags->lists('id'))) |
|
| 125 | - return; |
|
| 124 | + if (!$post || (!$tagIds = $post->tags->lists('id'))) { |
|
| 125 | + return; |
|
| 126 | + } |
|
| 126 | 127 | |
| 127 | 128 | // Start building our query for related posts |
| 128 | 129 | $query = Post::isPublished() |
@@ -10,7 +10,6 @@ |
||
| 10 | 10 | use Backend\Behaviors\FormController; |
| 11 | 11 | use Backend\Behaviors\ListController; |
| 12 | 12 | use October\Rain\Exception\SystemException; |
| 13 | -use October\Rain\Flash\FlashBag; |
|
| 14 | 13 | |
| 15 | 14 | /** |
| 16 | 15 | * Class Tags |
@@ -2,7 +2,6 @@ |
||
| 2 | 2 | |
| 3 | 3 | namespace GinoPane\BlogTaxonomy\Components; |
| 4 | 4 | |
| 5 | -use DB; |
|
| 6 | 5 | use Cms\Classes\Page; |
| 7 | 6 | use Cms\Classes\ComponentBase; |
| 8 | 7 | use GinoPane\BlogTaxonomy\Plugin; |