Code Duplication    Length = 8-8 lines in 2 locations

htdocs/class/userutility.php 1 location

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

htdocs/include/comment_post.php 1 location

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