Code Duplication    Length = 9-9 lines in 2 locations

lib/Command/CirclesRemote.php 2 locations

@@ 503-511 (lines=9) @@
500
	/**
501
	 * @throws Exception
502
	 */
503
	private function getRemoteType(): string {
504
		foreach (RemoteInstance::$LIST_TYPE as $type) {
505
			if (strtolower($this->input->getOption('type')) === strtolower($type)) {
506
				return $type;
507
			}
508
		}
509
510
		throw new Exception('Unknown type: ' . implode(', ', RemoteInstance::$LIST_TYPE));
511
	}
512
513
	/**
514
	 * @throws Exception
@@ 516-524 (lines=9) @@
513
	/**
514
	 * @throws Exception
515
	 */
516
	private function getRemoteInterface(): int {
517
		foreach (InterfaceService::$LIST_IFACE as $iface => $def) {
518
			if (strtolower($this->input->getOption('iface')) === strtolower($def)) {
519
				return $iface;
520
			}
521
		}
522
523
		throw new Exception('Unknown interface: ' . implode(', ', InterfaceService::$LIST_IFACE));
524
	}
525
526
}
527