1 | <?php |
||
12 | class quickmod |
||
13 | { |
||
14 | /** @var \phpbb\auth\auth */ |
||
15 | protected $auth; |
||
16 | |||
17 | /** @var \phpbb\template\template */ |
||
18 | protected $template; |
||
19 | |||
20 | /** @var \phpbb\user */ |
||
21 | protected $user; |
||
22 | |||
23 | /** @var string */ |
||
24 | protected $phpbb_root_path; |
||
25 | |||
26 | /** @var string */ |
||
27 | protected $php_ext; |
||
28 | |||
29 | /** |
||
30 | * Constructor |
||
31 | * |
||
32 | * @param \phpbb\auth\auth $auth Auth object |
||
33 | * @param \phpbb\template\template $template Template object |
||
34 | * @param \phpbb\user $user User object |
||
35 | * @param string $phpbb_root_path Path to the phpbb includes directory. |
||
36 | * @param string $php_ext php file extension |
||
37 | */ |
||
38 | public function __construct(\phpbb\auth\auth $auth, \phpbb\template\template $template, \phpbb\user $user, $phpbb_root_path, $php_ext) |
||
46 | |||
47 | /** |
||
48 | * @param array $topic_data |
||
49 | * @return void |
||
50 | */ |
||
51 | public function show_tools(array $topic_data) |
||
76 | |||
77 | /** |
||
78 | * @param array $topic_data |
||
79 | * @return void |
||
80 | */ |
||
81 | protected function get_options(array $topic_data) |
||
102 | |||
103 | /** |
||
104 | * @param array $topic_data |
||
105 | * @return bool |
||
106 | */ |
||
107 | protected function allow_topic_lock(array $topic_data) |
||
111 | |||
112 | /** |
||
113 | * @param array $topic_data |
||
114 | * @return bool |
||
115 | */ |
||
116 | protected function allow_topic_unlock(array $topic_data) |
||
120 | |||
121 | /** |
||
122 | * @param array $topic_data |
||
123 | * @return bool |
||
124 | */ |
||
125 | protected function allow_topic_delete(array $topic_data) |
||
129 | |||
130 | /** |
||
131 | * @param array $topic_data |
||
132 | * @return bool |
||
133 | */ |
||
134 | protected function allow_topic_restore(array $topic_data) |
||
138 | |||
139 | /** |
||
140 | * @param int $poster_id |
||
141 | * @return bool |
||
142 | */ |
||
143 | protected function user_is_topic_poster($poster_id) |
||
147 | |||
148 | /** |
||
149 | * @param int $forum_id |
||
150 | * @param int $poster_id |
||
151 | * @return bool |
||
152 | */ |
||
153 | protected function user_can_lock_topic($forum_id, $poster_id) |
||
157 | |||
158 | /** |
||
159 | * @param int $forum_id |
||
160 | * @param int $topic_type |
||
161 | * @return bool |
||
162 | */ |
||
163 | protected function allow_make_normal($forum_id, $topic_type) |
||
167 | |||
168 | /** |
||
169 | * @param int $forum_id |
||
170 | * @param int $topic_type |
||
171 | * @return bool |
||
172 | */ |
||
173 | protected function allow_make_sticky($forum_id, $topic_type) |
||
177 | |||
178 | /** |
||
179 | * @param int $forum_id |
||
180 | * @param int $topic_type |
||
181 | * @return bool |
||
182 | */ |
||
183 | protected function allow_make_announce($forum_id, $topic_type) |
||
187 | |||
188 | /** |
||
189 | * @param int $forum_id |
||
190 | * @param int $topic_type |
||
191 | * @return bool |
||
192 | */ |
||
193 | protected function allow_make_global($forum_id, $topic_type) |
||
197 | } |
||
198 |
This check marks access to variables or properties that have not been declared yet. While PHP has no explicit notion of declaring a variable, accessing it before a value is assigned to it is most likely a bug.