Code Duplication    Length = 11-12 lines in 2 locations

lib/private/Files/View.php 2 locations

@@ 859-870 (lines=12) @@
856
			try {
857
858
				$exists = $this->file_exists($path2);
859
				if ($this->shouldEmitHooks()) {
860
					\OC_Hook::emit(
861
						Filesystem::CLASSNAME,
862
						Filesystem::signal_copy,
863
						[
864
							Filesystem::signal_param_oldpath => $this->getHookPath($path1),
865
							Filesystem::signal_param_newpath => $this->getHookPath($path2),
866
							Filesystem::signal_param_run => &$run
867
						]
868
					);
869
					$this->emit_file_hooks_pre($exists, $path2, $run);
870
				}
871
				if ($run) {
872
					$mount1 = $this->getMount($path1);
873
					$mount2 = $this->getMount($path2);
@@ 897-907 (lines=11) @@
894
					$this->changeLock($path2, ILockingProvider::LOCK_SHARED);
895
					$lockTypePath2 = ILockingProvider::LOCK_SHARED;
896
897
					if ($this->shouldEmitHooks() && $result !== false) {
898
						\OC_Hook::emit(
899
							Filesystem::CLASSNAME,
900
							Filesystem::signal_post_copy,
901
							[
902
								Filesystem::signal_param_oldpath => $this->getHookPath($path1),
903
								Filesystem::signal_param_newpath => $this->getHookPath($path2)
904
							]
905
						);
906
						$this->emit_file_hooks_post($exists, $path2);
907
					}
908
909
				}
910
			} catch (\Exception $e) {