Code Duplication    Length = 13-14 lines in 2 locations

htdocs/xoops_lib/modules/protector/library/HTMLPurifier/Lexer/PH5P.php 2 locations

@@ 3733-3745 (lines=13) @@
3730
            /* If the stack of open elements does not have an element in table
3731
            scope with the same tag name as the token, this is a parse error.
3732
            Ignore the token. */
3733
            if (!$this->elementInScope($token['name'], true)) {
3734
                // Ignore
3735
3736
                /* Otherwise: */
3737
            } else {
3738
                /* Clear the stack back to a table body context. */
3739
                $this->clearStackToTableContext($clear);
3740
3741
                /* Pop the current node from the stack of open elements. Switch
3742
                the insertion mode to "in table". */
3743
                array_pop($this->stack);
3744
                $this->mode = self::IN_TABLE;
3745
            }
3746
3747
            /* A start tag whose tag name is one of: "caption", "col", "colgroup",
3748
            "tbody", "tfoot", "thead", or an end tag whose tag name is "table" */
@@ 3821-3834 (lines=14) @@
3818
            /* If the stack of open elements does not have an element in table
3819
            scope with the same tag name as the token, this is a parse error.
3820
            Ignore the token. (innerHTML case) */
3821
            if (!$this->elementInScope($token['name'], true)) {
3822
                // Ignore.
3823
3824
                /* Otherwise: */
3825
            } else {
3826
                /* Clear the stack back to a table row context. */
3827
                $this->clearStackToTableContext($clear);
3828
3829
                /* Pop the current node (which will be a tr element) from the
3830
                stack of open elements. Switch the insertion mode to "in table
3831
                body". */
3832
                array_pop($this->stack);
3833
                $this->mode = self::IN_TBODY;
3834
            }
3835
3836
            /* A start tag whose tag name is one of: "caption", "col", "colgroup",
3837
            "tbody", "tfoot", "thead", "tr" or an end tag whose tag name is "table" */