remove unused componets
This commit is contained in:
@@ -1,23 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Custom URL Encode function.
|
|
||||||
*
|
|
||||||
* @param string $string The string to encode.
|
|
||||||
* @param array|null $replaceArray Extra replacements to make.
|
|
||||||
* @return string The encoded string.
|
|
||||||
*/
|
|
||||||
function customUrlEncode(string $string, array|null $replaceArray = null): string {
|
|
||||||
// If $replaceArray is null, use the default [' ' => '%20']
|
|
||||||
if ($replaceArray === null) {
|
|
||||||
$replaceArray = [' ' => '%20'];
|
|
||||||
}
|
|
||||||
|
|
||||||
// If $replaceArray is an array and not empty, perform the replacements
|
|
||||||
if (is_array($replaceArray) && !empty($replaceArray)) {
|
|
||||||
$string = str_replace(array_keys($replaceArray), array_values($replaceArray), $string);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Finally, use urlencode
|
|
||||||
return urlencode($string);
|
|
||||||
}
|
|
||||||
@@ -37,8 +37,7 @@
|
|||||||
"files": [
|
"files": [
|
||||||
"app/Helpers/Array.php",
|
"app/Helpers/Array.php",
|
||||||
"app/Helpers/Temp.php",
|
"app/Helpers/Temp.php",
|
||||||
"app/Helpers/TypeValue.php",
|
"app/Helpers/TypeValue.php"
|
||||||
"app/Helpers/URLEncode.php"
|
|
||||||
],
|
],
|
||||||
"psr-4": {
|
"psr-4": {
|
||||||
"App\\": "app/",
|
"App\\": "app/",
|
||||||
|
|||||||
Reference in New Issue
Block a user