File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -62,8 +62,8 @@ public function browserInfo($user_agent = null)
6262
6363 // finally get the correct version number
6464 // Added "|:"
65- $ known = array ( 'Version ' , $ ub , 'other ' ) ;
66- $ pattern = '#(?<browser> ' .join ('| ' , $ known ).')[/|: ]+(?<version>[0-9.|a-zA-Z.]*)# ' ;
65+ $ known = [ 'Version ' , $ ub , 'other ' ] ;
66+ $ pattern = '#(?<browser> ' .implode ('| ' , $ known ).')[/|: ]+(?<version>[0-9.|a-zA-Z.]*)# ' ;
6767 if (!preg_match_all ($ pattern , $ user_agent , $ matches )) {
6868 // we have no matching number just continue
6969 }
@@ -87,12 +87,12 @@ public function browserInfo($user_agent = null)
8787 $ version = '? ' ;
8888 }
8989
90- return array (
90+ return [
9191 'userAgent ' => $ user_agent ,
9292 'name ' => $ bname ,
9393 'version ' => $ version ,
9494 'platform ' => $ platform ,
9595 'pattern ' => $ pattern ,
96- ) ;
96+ ] ;
9797 }
9898}
You can’t perform that action at this time.
0 commit comments