Test Failed
Push — master ( 9cda24...b707d5 )
by Joe
02:13
created
src/Fantastico.php 1 patch
Upper-Lower-Casing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
 	 */
82 82
 	public function __construct($username, $password) {
83 83
 		$this->cache = [];
84
-		$this->soapClient = NULL;
84
+		$this->soapClient = null;
85 85
 		$this->apiUsername = $username;
86 86
 		$this->apiPassword = $password;
87 87
 	}
@@ -164,9 +164,9 @@  discard block
 block discarded – undo
164 164
 		if (isset($this->cache['getIpList_'.$type]))
165 165
 			return $this->cache['getIpList_'.$type];
166 166
 		if (!$this->isType($type))
167
-			return FALSE;
167
+			return false;
168 168
 		$this->connect();
169
-		$this->cache['getIpList_'.$type] = json_decode($this->soapClient->getIpList($this->getHash(), $type), TRUE);
169
+		$this->cache['getIpList_'.$type] = json_decode($this->soapClient->getIpList($this->getHash(), $type), true);
170 170
 		myadmin_log('fantastico', 'debug', json_encode($this->cache['getIpList_'.$type]), __LINE__, __FILE__);
171 171
 		return $this->cache['getIpList_'.$type];
172 172
 	}
@@ -214,12 +214,12 @@  discard block
 block discarded – undo
214 214
 	 */
215 215
 	public function getIpListDetailed($type = self::ALL_TYPES) {
216 216
 		if (!$this->isType($type))
217
-			return FALSE;
217
+			return false;
218 218
 		if (isset($this->cache['getIpListDetailed_'.$type]))
219 219
 			return $this->cache['getIpListDetailed_'.$type];
220 220
 		$this->connect();
221 221
 		//try {
222
-		$response = json_decode($this->soapClient->__soapCall('getIpListDetailed', [$this->getHash(), $type]), TRUE);
222
+		$response = json_decode($this->soapClient->__soapCall('getIpListDetailed', [$this->getHash(), $type]), true);
223 223
 		myadmin_log('fantastico', 'debug', json_encode($response), __LINE__, __FILE__);
224 224
 		//echo '<pre>';echo print_r($response, TRUE);echo '</pre>';
225 225
 		//$this->cache['getIpListDetailed_'.$type] = $this->cache['getIpListDetailed_'.$type]->Licenses;
@@ -260,7 +260,7 @@  discard block
 block discarded – undo
260 260
 	 * @return bool whether or not the ip was validated
261 261
 	 */
262 262
 	public function validIp($ipAddress) {
263
-		return ip2long($ipAddress) !== FALSE;
263
+		return ip2long($ipAddress) !== false;
264 264
 	}
265 265
 
266 266
 	/**
@@ -294,7 +294,7 @@  discard block
 block discarded – undo
294 294
 		if (isset($this->cache['getIpDetails_'.$ipAddress]))
295 295
 			return $this->cache['getIpDetails_'.$ipAddress];
296 296
 		$this->connect();
297
-		$this->cache['getIpDetails_'.$ipAddress] = json_decode($this->soapClient->getIpDetails($this->getHash(), $ipAddress), TRUE);
297
+		$this->cache['getIpDetails_'.$ipAddress] = json_decode($this->soapClient->getIpDetails($this->getHash(), $ipAddress), true);
298 298
 		myadmin_log('fantastico', 'debug', json_encode($this->cache['getIpDetails_'.$ipAddress]), __LINE__, __FILE__);
299 299
 		return $this->cache['getIpDetails_'.$ipAddress];
300 300
 	}
@@ -372,7 +372,7 @@  discard block
 block discarded – undo
372 372
 			$response = ['faultcode' => 2, 'fault' => 'Invalid IP Address '.$newip];
373 373
 		} else {
374 374
 			$this->connect();
375
-			$response = json_decode($this->soapClient->editIp($this->getHash(), $ipAddress, $newip), TRUE);
375
+			$response = json_decode($this->soapClient->editIp($this->getHash(), $ipAddress, $newip), true);
376 376
 			myadmin_log('fantastico', 'debug', json_encode($response), __LINE__, __FILE__);
377 377
 			if (isset($response['fault '])) {
378 378
 				$response['fault'] = $response['fault '];
@@ -450,7 +450,7 @@  discard block
 block discarded – undo
450 450
 			$response = ['faultcode' => 1, 'fault' => 'Invalid IP Address '.$ipAddress];
451 451
 		} else {
452 452
 			$this->connect();
453
-			$response = json_decode($this->soapClient->addIp($this->getHash(), $ipAddress, $type), TRUE);
453
+			$response = json_decode($this->soapClient->addIp($this->getHash(), $ipAddress, $type), true);
454 454
 			myadmin_log('fantastico', 'debug', json_encode($response), __LINE__, __FILE__);
455 455
 			if (isset($response['fault '])) {
456 456
 				$response['fault'] = $response['fault '];
@@ -470,7 +470,7 @@  discard block
 block discarded – undo
470 470
 		if (!$this->validIp($ipAddress))
471 471
 			return ['faultcode' => 1, 'fault ' => 'Invalid IP Address '.$ipAddress];
472 472
 		$this->connect();
473
-		$response = json_decode($this->soapClient->$function($this->getHash(), $ipAddress), TRUE);
473
+		$response = json_decode($this->soapClient->$function($this->getHash(), $ipAddress), true);
474 474
 		myadmin_log('fantastico', 'debug', json_encode($response), __LINE__, __FILE__);
475 475
 		$this->cache = [];
476 476
 		return $response;
Please login to merge, or discard this patch.