Code Duplication    Length = 10-10 lines in 2 locations

lib/private/Files/View.php 2 locations

@@ 231-240 (lines=10) @@
228
	 * @param string $path
229
	 * @return string
230
	 */
231
	public function getLocalFile($path) {
232
		$parent = substr($path, 0, strrpos($path, '/'));
233
		$path = $this->getAbsolutePath($path);
234
		list($storage, $internalPath) = Filesystem::resolvePath($path);
235
		if (Filesystem::isValidPath($parent) and $storage) {
236
			return $storage->getLocalFile($internalPath);
237
		} else {
238
			return null;
239
		}
240
	}
241
242
	/**
243
	 * @param string $path
@@ 246-255 (lines=10) @@
243
	 * @param string $path
244
	 * @return string
245
	 */
246
	public function getLocalFolder($path) {
247
		$parent = substr($path, 0, strrpos($path, '/'));
248
		$path = $this->getAbsolutePath($path);
249
		list($storage, $internalPath) = Filesystem::resolvePath($path);
250
		if (Filesystem::isValidPath($parent) and $storage) {
251
			return $storage->getLocalFolder($internalPath);
252
		} else {
253
			return null;
254
		}
255
	}
256
257
	/**
258
	 * the following functions operate with arguments and return values identical