Code Duplication    Length = 11-11 lines in 2 locations

src/Cloudlinux.php 2 locations

@@ 283-293 (lines=11) @@
280
	 * @param bool $checkAll True will search for any type of license. False ­ only for types 1 or 2
281
	 * @return false|array (list<int>): List of registered license types or empty list if no license found
282
	 */
283
	public function xmlIsLicensed($ipAddress, $checkAll = true) {
284
		$xmlClient = $this->xmlClient;
285
		try {
286
			$this->response = $xmlClient->isLicensed($this->authToken(), $ipAddress, $checkAll);
287
		} catch (\Exception $e) {
288
			$this->log('error', 'Caught exception code: ' . $e->getCode());
289
			$this->log('error', 'Caught exception message: ' . $e->getMessage());
290
			return false;
291
		}
292
		return $this->response;
293
	}
294
295
	/**
296
	 * @return false|array
@@ 314-324 (lines=11) @@
311
	 * @throws XmlRpcException for critical errors
312
	 * @return false|array (list<structure>): List of structures or empty list. Each structure contains keys:  IP(string)   TYPE(int) ­ license type  REGISTERED(boolean) ­ True if server was registered in CLN with this license
313
	 */
314
	public function reconcile() {
315
		$xmlClient = $this->xmlClient;
316
		try {
317
			$this->response = $xmlClient->reconcile($this->authToken());
318
		} catch (\Exception $e) {
319
			$this->log('error', 'Caught exception code: ' . $e->getCode());
320
			$this->log('error', 'Caught exception message: ' . $e->getMessage());
321
			return false;
322
		}
323
		return $this->reseponse;
324
	}
325
}
326
327