Code Duplication    Length = 8-8 lines in 2 locations

htdocs/include/comment_post.php 1 location

@@ 193-200 (lines=8) @@
190
            $error_message .= _US_EMAILNOSPACES . '<br>';
191
        }
192
        // Check forbidden email address if current operator is not an administrator
193
        if (!$xoopsUser_isAdmin) {
194
            foreach ($xoopsConfigUser['bad_emails'] as $be) {
195
                if (!empty($be) && preg_match('/' . $be . '/i', $com_email)) {
196
                    $error_message .= _US_INVALIDMAIL . '<br>';
197
                    break;
198
                }
199
            }
200
        }
201
        if (!empty($error_message)) {
202
            $op = 'preview';
203
        }

htdocs/class/userutility.php 1 location

@@ 135-142 (lines=8) @@
132
            $stop .= _US_EMAILNOSPACES . '<br>';
133
        }
134
        // Check forbidden email address if current operator is not an administrator
135
        if (!$xoopsUser_isAdmin) {
136
            foreach ($xoopsConfigUser['bad_emails'] as $be) {
137
                if (!empty($be) && preg_match('/' . $be . '/i', $email)) {
138
                    $stop .= _US_INVALIDMAIL . '<br>';
139
                    break;
140
                }
141
            }
142
        }
143
        $uname = xoops_trim($uname);
144
        switch ($xoopsConfigUser['uname_test_level']) {
145
            case 0: