Code Duplication    Length = 9-9 lines in 2 locations

apps/files_sharing/lib/External/Storage.php 1 location

@@ 146-154 (lines=9) @@
143
	 * @param \OC\Files\Storage\Storage $storage
144
	 * @return \OCA\Files_Sharing\External\Scanner
145
	 */
146
	public function getScanner($path = '', $storage = null) {
147
		if (!$storage) {
148
			$storage = $this;
149
		}
150
		if (!isset($this->scanner)) {
151
			$this->scanner = new Scanner($storage);
152
		}
153
		return $this->scanner;
154
	}
155
156
	/**
157
	 * check if a file or folder has been updated since $time

lib/private/Files/ObjectStore/ObjectStoreStorage.php 1 location

@@ 141-149 (lines=9) @@
138
	 * @param \OC\Files\Storage\Storage (optional) the storage to pass to the scanner
139
	 * @return \OC\Files\ObjectStore\NoopScanner
140
	 */
141
	public function getScanner($path = '', $storage = null) {
142
		if (!$storage) {
143
			$storage = $this;
144
		}
145
		if (!isset($this->scanner)) {
146
			$this->scanner = new NoopScanner($storage);
147
		}
148
		return $this->scanner;
149
	}
150
151
	public function getId() {
152
		return $this->id;