| Conditions | 7 |
| Paths | 2 |
| Total Lines | 12 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 56 |
| Changes | 0 | ||
| 1 | <?php |
||
| 28 | public static function hooks(\Event_Manager $eventsManager) |
||
| 29 | { |
||
| 30 | global $user_info, $modSettings; |
||
| 31 | |||
| 32 | if (!$user_info['is_admin'] && !$user_info['is_moderator'] && !empty($modSettings['posts_require_captcha']) && ($user_info['posts'] < $modSettings['posts_require_captcha'] || ($user_info['is_guest'] && $modSettings['posts_require_captcha'] == -1))) |
||
| 33 | { |
||
| 34 | return array( |
||
| 35 | array('topicinfo', array('Verification_Display_Module', 'topicinfo'), array()), |
||
| 36 | ); |
||
| 37 | } |
||
| 38 | else |
||
| 39 | return array(); |
||
| 40 | } |
||
| 57 | } |