File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -60,7 +60,7 @@ public function offsetUnset($offset)
6060 */
6161 protected function formatString ($ str )
6262 {
63- if (extension_loaded ( ' mbstring ' )) {
63+ if (function_exists ( ' mb_convert_case ' )) {
6464 $ str = mb_convert_case ($ str , MB_CASE_TITLE , 'UTF-8 ' );
6565 } else {
6666 $ str = $ this ->lowerize ($ str );
@@ -82,7 +82,7 @@ protected function formatString($str)
8282 */
8383 protected function lowerize ($ str )
8484 {
85- return extension_loaded ( ' mbstring ' ) ? mb_strtolower ($ str , 'UTF-8 ' ) : strtolower ($ str );
85+ return function_exists ( ' mb_strtolower ' ) ? mb_strtolower ($ str , 'UTF-8 ' ) : strtolower ($ str );
8686 }
8787
8888 /**
@@ -94,6 +94,6 @@ protected function lowerize($str)
9494 */
9595 protected function upperize ($ str )
9696 {
97- return extension_loaded ( ' mbstring ' ) ? mb_strtoupper ($ str , 'UTF-8 ' ) : strtoupper ($ str );
97+ return function_exists ( ' mb_strtoupper ' ) ? mb_strtoupper ($ str , 'UTF-8 ' ) : strtoupper ($ str );
9898 }
9999}
Original file line number Diff line number Diff line change 11<?php
22
3- if (!extension_loaded ( ' curl ' ) || ! function_exists ('curl_init ' )) {
3+ if (!function_exists ('curl_init ' )) {
44 die (<<<EOT
55cURL has to be enabled!
66EOT
You can’t perform that action at this time.
0 commit comments