Code Duplication    Length = 11-11 lines in 2 locations

src/Stringy.php 2 locations

@@ 1014-1024 (lines=11) @@
1011
     * @return static
1012
     *                <p>Object with the resulting $str after being html decoded.</p>
1013
     */
1014
    public function htmlDecode(int $flags = \ENT_COMPAT): self
1015
    {
1016
        return static::create(
1017
            $this->utf8::html_entity_decode(
1018
                $this->str,
1019
                $flags,
1020
                $this->encoding
1021
            ),
1022
            $this->encoding
1023
        );
1024
    }
1025
1026
    /**
1027
     * Convert all applicable characters to HTML entities.
@@ 1082-1092 (lines=11) @@
1079
     * @return static
1080
     *                <p>Object with the resulting $str after being html encoded.</p>
1081
     */
1082
    public function htmlEncode(int $flags = \ENT_COMPAT): self
1083
    {
1084
        return static::create(
1085
            $this->utf8::htmlentities(
1086
                $this->str,
1087
                $flags,
1088
                $this->encoding
1089
            ),
1090
            $this->encoding
1091
        );
1092
    }
1093
1094
    /**
1095
     * Capitalizes the first word of the string, replaces underscores with