@@ -143,12 +143,12 @@ public function Connect( $Ip, $Port, $Timeout = 3, $Engine = self :: SOURCE )
143143
144144 if ( !is_int ( $ Timeout ) || $ Timeout < 0 )
145145 {
146- throw new InvalidArgumentException (" Timeout must be an integer. " , InvalidArgumentException::TIMEOUT_NOT_INTEGER );
146+ throw new InvalidArgumentException ( ' Timeout must be an integer. ' , InvalidArgumentException::TIMEOUT_NOT_INTEGER );
147147 }
148148
149149 if ( !$ this ->Socket ->Open ( $ Ip , (int )$ Port , $ Timeout , (int )$ Engine ) )
150150 {
151- throw new TimeoutException (" Could not connect to server. " , TimeoutException::TIMEOUT_CONNECT );
151+ throw new TimeoutException ( ' Could not connect to server. ' , TimeoutException::TIMEOUT_CONNECT );
152152 }
153153
154154 $ this ->Connected = true ;
@@ -279,7 +279,7 @@ public function GetInfo( )
279279
280280 if ( $ Type !== self :: S2A_INFO )
281281 {
282- throw new InvalidPacketException (" GetInfo: Packet header mismatch. (0x' . DecHex( $ Type ) . ') " , InvalidPacketException::PACKET_HEADER_MISMATCH );
282+ throw new InvalidPacketException ( ' GetInfo: Packet header mismatch. (0x ' . DecHex ( $ Type ) . ') ' , InvalidPacketException::PACKET_HEADER_MISMATCH );
283283 }
284284
285285 $ Server [ 'Protocol ' ] = $ this ->Buffer ->GetByte ( );
@@ -344,8 +344,8 @@ public function GetInfo( )
344344
345345 if ( $ this ->Buffer ->Remaining ( ) > 0 )
346346 {
347- throw new InvalidPacketException (" GetInfo: unread data? " . $ this ->Buffer ->Remaining ( ) . " bytes remaining in the buffer. Please report it to the library developer. " ,
348- InvalidPacketException::BUFFER_NOT_EMPTY );
347+ throw new InvalidPacketException ( ' GetInfo: unread data? ' . $ this ->Buffer ->Remaining ( ) . ' bytes remaining in the buffer. Please report it to the library developer. ' ,
348+ InvalidPacketException::BUFFER_NOT_EMPTY );
349349 }
350350 }
351351
@@ -386,7 +386,7 @@ public function GetPlayers( )
386386 }
387387 else if ( $ Type !== self :: S2A_PLAYER )
388388 {
389- throw new InvalidPacketException ( 'GetPlayers: Packet header mismatch. (0x ' . DecHex ( $ Type ) . ') ' , InvalidPacketException::PACKET_HEADER_MISMATCH );
389+ throw new InvalidPacketException ( 'GetPlayers: Packet header mismatch. (0x ' . DecHex ( $ Type ) . ') ' , InvalidPacketException::PACKET_HEADER_MISMATCH );
390390 }
391391
392392 break ;
@@ -443,7 +443,7 @@ public function GetRules( )
443443 }
444444 else if ( $ Type !== self :: S2A_RULES )
445445 {
446- throw new InvalidPacketException ( 'GetRules: Packet header mismatch. (0x ' . DecHex ( $ Type ) . ') ' , InvalidPacketException::PACKET_HEADER_MISMATCH );
446+ throw new InvalidPacketException ( 'GetRules: Packet header mismatch. (0x ' . DecHex ( $ Type ) . ') ' , InvalidPacketException::PACKET_HEADER_MISMATCH );
447447 }
448448
449449 break ;
@@ -512,7 +512,7 @@ private function GetChallenge( $Header, $ExpectedResult )
512512 }
513513 default :
514514 {
515- throw new InvalidPacketException ( 'GetChallenge: Packet header mismatch. (0x ' . DecHex ( $ Type ) . ') ' , InvalidPacketException::PACKET_HEADER_MISMATCH );
515+ throw new InvalidPacketException ( 'GetChallenge: Packet header mismatch. (0x ' . DecHex ( $ Type ) . ') ' , InvalidPacketException::PACKET_HEADER_MISMATCH );
516516 }
517517 }
518518 }
0 commit comments