@@ -121,7 +121,7 @@ |
||
121 | 121 | * Removes user with uuid `$id` from UserOnline |
122 | 122 | * |
123 | 123 | * @param string $id id |
124 | - * @return bool |
|
124 | + * @return integer |
|
125 | 125 | */ |
126 | 126 | public function setOffline($id) |
127 | 127 | { |
@@ -9,9 +9,6 @@ |
||
9 | 9 | |
10 | 10 | namespace App\Model\Table; |
11 | 11 | |
12 | -use ArrayObject; |
|
13 | -use Cake\Event\Event; |
|
14 | -use Cake\ORM\Entity; |
|
15 | 12 | use Cake\ORM\Query; |
16 | 13 | use Cake\ORM\Table; |
17 | 14 | use Cake\Validation\Validator; |
@@ -368,7 +368,7 @@ |
||
368 | 368 | * set last refresh |
369 | 369 | * |
370 | 370 | * @param int $userId user-ID |
371 | - * @param null $lastRefresh last refresh |
|
371 | + * @param integer $lastRefresh last refresh |
|
372 | 372 | * @return void |
373 | 373 | */ |
374 | 374 | public function setLastRefresh($userId, $lastRefresh = null) |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | $this->addBehavior( |
78 | 78 | 'Proffer.Proffer', |
79 | 79 | [ |
80 | - 'avatar' => [ // The name of your upload field (filename) |
|
80 | + 'avatar' => [// The name of your upload field (filename) |
|
81 | 81 | 'root' => $avatarRootDir, |
82 | 82 | 'dir' => 'avatar_dir', // field for upload directory |
83 | 83 | 'thumbnailSizes' => [ |
@@ -793,8 +793,8 @@ discard block |
||
793 | 793 | $User->set('user_category_custom', $newCats); |
794 | 794 | } else { |
795 | 795 | //=if set a single category |
796 | - $category = (int)$category; |
|
797 | - if ($category > 0 && $this->Entries->Categories->exists((int)$category) |
|
796 | + $category = (int) $category; |
|
797 | + if ($category > 0 && $this->Entries->Categories->exists((int) $category) |
|
798 | 798 | ) { |
799 | 799 | $active = $category; |
800 | 800 | } else { |
@@ -9,7 +9,6 @@ |
||
9 | 9 | |
10 | 10 | namespace App\View\Helper; |
11 | 11 | |
12 | -use App\Controller\Component\CurrentUserComponent; |
|
13 | 12 | use Cake\Core\Configure; |
14 | 13 | use Cake\Event\Event; |
15 | 14 | use Cake\View\Helper; |
@@ -63,7 +63,7 @@ discard block |
||
63 | 63 | 'version' => Configure::read('Saito.v'), |
64 | 64 | 'settings' => [ |
65 | 65 | 'autoPageReload' => (isset($View->viewVars['autoPageReload']) ? $View->viewVars['autoPageReload'] : 0), |
66 | - 'editPeriod' => (int)Configure::read( |
|
66 | + 'editPeriod' => (int) Configure::read( |
|
67 | 67 | 'Saito.Settings.edit_period' |
68 | 68 | ), |
69 | 69 | 'language' => Configure::read('Saito.language'), |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | 'csrf' => $this->_getCsrf($View) |
90 | 90 | ], |
91 | 91 | 'currentUser' => [ |
92 | - 'id' => (int)$CurrentUser->get('id'), |
|
92 | + 'id' => (int) $CurrentUser->get('id'), |
|
93 | 93 | 'username' => $CurrentUser->get('username'), |
94 | 94 | 'user_show_inline' => $CurrentUser->get('inline_view_on_click') || false, |
95 | 95 | 'user_show_thread_collapsed' => $CurrentUser->get('user_show_thread_collapsed') || false |
@@ -12,12 +12,10 @@ |
||
12 | 12 | |
13 | 13 | namespace App\View\Helper; |
14 | 14 | |
15 | -use Cake\Core\Configure; |
|
16 | 15 | use Geshi\View\Helper\GeshiHelper; |
17 | 16 | use Saito\App\Registry; |
18 | 17 | use Saito\Markup\Markup; |
19 | 18 | use Saito\Markup\MarkupInterface; |
20 | -use Saito\Smiley\SmileyRenderer; |
|
21 | 19 | use Stopwatch\Lib\Stopwatch; |
22 | 20 | |
23 | 21 | /** |
@@ -86,7 +86,7 @@ |
||
86 | 86 | /** |
87 | 87 | * get editor help |
88 | 88 | * |
89 | - * @return mixed |
|
89 | + * @return string |
|
90 | 90 | */ |
91 | 91 | public function editorHelp() |
92 | 92 | { |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * Saito - The Threaded Web Forum |
@@ -79,7 +79,7 @@ |
||
79 | 79 | * Translates user types |
80 | 80 | * |
81 | 81 | * @param string $type type |
82 | - * @return mixed |
|
82 | + * @return string|null |
|
83 | 83 | */ |
84 | 84 | public function type($type) |
85 | 85 | { |
@@ -10,11 +10,9 @@ |
||
10 | 10 | namespace App\View\Helper; |
11 | 11 | |
12 | 12 | use App\Model\Entity\User; |
13 | -use Cake\ORM\Entity; |
|
14 | 13 | use Identicon\Identicon; |
15 | 14 | use Saito\RememberTrait; |
16 | 15 | use Saito\User\ForumsUserInterface; |
17 | -use Saito\User\SaitoUser; |
|
18 | 16 | use Stopwatch\Lib\Stopwatch; |
19 | 17 | |
20 | 18 | /** |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | public function run() |
20 | 20 | { |
21 | 21 | $data = |
22 | - [ |
|
22 | + [ |
|
23 | 23 | [ |
24 | 24 | 'id' => 1, |
25 | 25 | 'sort' => 1, |
@@ -105,7 +105,7 @@ discard block |
||
105 | 105 | 'sort' => 17, |
106 | 106 | 'icon' => 'angry', |
107 | 107 | ] |
108 | - ]; |
|
108 | + ]; |
|
109 | 109 | |
110 | 110 | $table = $this->table('smilies'); |
111 | 111 | $table->insert($data)->save(); |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * Saito - The Threaded Web Forum |
@@ -15,7 +15,7 @@ |
||
15 | 15 | use Saito\Exception\SaitoForbiddenException; |
16 | 16 | use Saito\Test\IntegrationTestCase; |
17 | 17 | |
18 | - /* |
|
18 | + /* |
|
19 | 19 | class SearchesMockController extends SearchesController |
20 | 20 | { |
21 | 21 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * Saito - The Threaded Web Forum |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * Saito - The Threaded Web Forum |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | $minWordLength = $connection |
94 | 94 | ->execute("SHOW VARIABLES LIKE 'ft_min_word_len'") |
95 | 95 | ->fetch()[1]; |
96 | - $options['searchTerm']->setMinWordLength((int)$minWordLength); |
|
96 | + $options['searchTerm']->setMinWordLength((int) $minWordLength); |
|
97 | 97 | |
98 | 98 | $query |
99 | 99 | ->where(['Entries.category_id IN' => $options['categories']]) |