-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[stable30] fix: Handle copy of folders containing live photos #49650
Conversation
62830a7
to
be7b6a7
Compare
Signed-off-by: Louis Chemineau <[email protected]>
79ebb1b
to
05be967
Compare
We need to recursively look for live photos in the folder, and then handle them as usual. Signed-off-by: Louis Chemineau <[email protected]>
Signed-off-by: Louis Chemineau <[email protected]>
Signed-off-by: Louis Chemineau <[email protected]>
f5565be
to
f2d2dc1
Compare
Signed-off-by: Louis Chemineau <[email protected]>
f2d2dc1
to
3497725
Compare
return $this->fileView->copy($sourcePath, $destinationPath); | ||
$copyOkay = $this->fileView->copy($sourcePath, $destinationPath); | ||
|
||
if (!$copyOkay) { |
Check notice
Code scanning / Psalm
RiskyTruthyFalsyComparison Note
if ($peerFileId === null) { | ||
return; | ||
} | ||
$peerFile = $this->userFolder->getFirstNodeById($peerFileId); |
Check notice
Code scanning / Psalm
PossiblyNullReference Note
if ($event instanceof BeforeNodeCopiedEvent) { | ||
$this->runMoveOrCopyChecks($sourceNode, $targetNode, $peerFile); | ||
} elseif ($event instanceof NodeCopiedEvent) { | ||
$this->handleCopy($sourceNode, $targetNode, $peerFile); |
Check notice
Code scanning / Psalm
ArgumentTypeCoercion Note
Backport of #49293
Warning, This backport's changes differ from the original and might be incomplete⚠️
Todo
Learn more about backports at https://docs.nextcloud.com/server/stable/go.php?to=developer-backports.