File tree Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Expand file tree Collapse file tree 3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -105,7 +105,7 @@ protected function _getConfig($path)
105
105
*/
106
106
public function isAbsolutePath ($ path )
107
107
{
108
- if (PHP_OS == " WINNT " ) {
108
+ if (strtoupper ( substr ( PHP_OS , 0 , 3 )) === ' WIN ' ) {
109
109
if (preg_match ('/^[A-Z]: \\\\/ ' , $ path )) {
110
110
return true ;
111
111
}
Original file line number Diff line number Diff line change @@ -364,7 +364,7 @@ public static function install($path)
364
364
$ path = rtrim (realpath ($ path ), '/ ' ) . '/ ' ;
365
365
$ tools = realpath (__DIR__ . '/../../../ ' );
366
366
367
- if (PHP_OS == ' WINNT ' ) {
367
+ if (strtoupper ( substr ( PHP_OS , 0 , 3 )) === ' WIN ' ) {
368
368
$ path = str_replace ("\\" , '/ ' , $ path );
369
369
$ tools = str_replace ("\\" , '/ ' , $ tools );
370
370
}
@@ -397,7 +397,7 @@ public static function install($path)
397
397
public static function uninstall ($ path )
398
398
{
399
399
$ path = realpath ($ path ) . '/ ' ;
400
- if (PHP_OS == ' WINNT ' ) {
400
+ if (strtoupper ( substr ( PHP_OS , 0 , 3 )) === ' WIN ' ) {
401
401
$ path = str_replace ("\\" , '/ ' , $ path );
402
402
}
403
403
Original file line number Diff line number Diff line change @@ -151,7 +151,7 @@ private function checkToolsIp($ip)
151
151
*/
152
152
public function isAbsolutePath ($ path )
153
153
{
154
- if (PHP_OS == " WINNT " ) {
154
+ if (strtoupper ( substr ( PHP_OS , 0 , 3 )) === ' WIN ' ) {
155
155
if (preg_match ('/^[A-Z]: \\\\/ ' , $ path )) {
156
156
return true ;
157
157
}
You can’t perform that action at this time.
0 commit comments