src/helpers/SearchHelper.php
private static function _getCharMap(): array
    {
        // Keep local copy
        static $map = [];

        if (empty($map)) {
            // This will replace accented chars with non-accented chars
            foreach (StringHelper::asciiCharMap() as $asciiChar => $charsArray) {
                foreach ($charsArray as $char) {
                    $map[$char] = $asciiChar;
                }
            }

            // Replace punctuation with a space
            foreach (self::_getPunctuation() as $value) {
                $map[$value] = ' ';
            }
        }

        // Return the char map
        return $map;
    }
private static function _getCharMap(): array
    {
        // Keep local copy
        static $map = [];

        if (empty($map)) {
            // This will replace accented chars with non-accented chars
            foreach (StringHelper::asciiCharMap() as $asciiChar => $charsArray) {
                foreach ($charsArray as $char) {
                    $map[$char] = $asciiChar;
                }
            }

            // Replace punctuation with a space
            foreach (self::_getPunctuation() as $value) {
                $map[$value] = ' ';
            }
        }

        // Return the char map
        return $map;
    }
private static function _getCharMap ( ) : array { // Keep local copy static $ map = [ ] ; if ( empty ( $ map ) ) { // This will replace accented chars with non-accented chars foreach ( StringHelper :: asciiCharMap ( ) as $ asciiChar => $ charsArray ) { foreach ( $ charsArray as $ char ) { $ map [ $ char ] = $ asciiChar ; } } // Replace punctuation with a space foreach ( self :: _getPunctuation ( ) as $ value ) { $ map [ $ value ] = ' ' ; } } // Return the char map return $ map ; }
Get array of chars to be used for conversion.

@return array
Get array of chars to be used for conversion .