Code Duplication    Length = 11-11 lines in 2 locations

src/Stringy.php 2 locations

@@ 1075-1085 (lines=11) @@
1072
     * @return static
1073
     *                <p>Object with the resulting $str after being html decoded.</p>
1074
     */
1075
    public function htmlDecode(int $flags = \ENT_COMPAT): self
1076
    {
1077
        return static::create(
1078
            $this->utf8::html_entity_decode(
1079
                $this->str,
1080
                $flags,
1081
                $this->encoding
1082
            ),
1083
            $this->encoding
1084
        );
1085
    }
1086
1087
    /**
1088
     * Convert all applicable characters to HTML entities.
@@ 1143-1153 (lines=11) @@
1140
     * @return static
1141
     *                <p>Object with the resulting $str after being html encoded.</p>
1142
     */
1143
    public function htmlEncode(int $flags = \ENT_COMPAT): self
1144
    {
1145
        return static::create(
1146
            $this->utf8::htmlentities(
1147
                $this->str,
1148
                $flags,
1149
                $this->encoding
1150
            ),
1151
            $this->encoding
1152
        );
1153
    }
1154
1155
    /**
1156
     * Capitalizes the first word of the string, replaces underscores with