Code Duplication    Length = 7-7 lines in 2 locations

EmailValidator/Parser/DomainPart.php 1 location

@@ 178-184 (lines=7) @@
175
                    $openedParenthesis--;
176
                }
177
            }
178
            if ($this->lexer->token['type'] === EmailLexer::S_CLOSEPARENTHESIS) {
179
                if ($openedParenthesis === 0) {
180
                    throw new UnopenedComment();
181
                } else {
182
                    $openedParenthesis--;
183
                }
184
            }
185
186
            $this->checkConsecutiveDots();
187
            $this->checkDomainPartExceptions($prev);

EmailValidator/Parser/LocalPart.php 1 location

@@ 45-51 (lines=7) @@
42
                $openedParenthesis += $this->getOpenedParenthesis();
43
            }
44
45
            if ($this->lexer->token['type'] === EmailLexer::S_CLOSEPARENTHESIS) {
46
                if ($openedParenthesis === 0) {
47
                    throw new UnopenedComment();
48
                }
49
50
                $openedParenthesis--;
51
            }
52
53
            $this->checkConsecutiveDots();
54