Skip to content

Commit ac7bb4a

Browse files
Carl Schwanbackportbot[bot]
authored andcommitted
fix(trash): Fix order of metadata deletion
First query metadata for live photo and then delete the metadata, by making the SyncLivePhotosListener priority higher than the default. Partially fix #54274 Signed-off-by: Carl Schwan <carl.schwan@nextclound.com>
1 parent a338e57 commit ac7bb4a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

apps/files/lib/AppInfo/Application.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ public function register(IRegistrationContext $context): void {
115115
$context->registerEventListener(RenderReferenceEvent::class, RenderReferenceEventListener::class);
116116
$context->registerEventListener(BeforeNodeRenamedEvent::class, SyncLivePhotosListener::class);
117117
$context->registerEventListener(BeforeNodeDeletedEvent::class, SyncLivePhotosListener::class);
118-
$context->registerEventListener(CacheEntryRemovedEvent::class, SyncLivePhotosListener::class);
118+
$context->registerEventListener(CacheEntryRemovedEvent::class, SyncLivePhotosListener::class, 1); // Ensure this happen before the metadata are deleted.
119119
$context->registerEventListener(BeforeNodeCopiedEvent::class, SyncLivePhotosListener::class);
120120
$context->registerEventListener(NodeCopiedEvent::class, SyncLivePhotosListener::class);
121121
$context->registerEventListener(LoadSearchPlugins::class, LoadSearchPluginsListener::class);

0 commit comments

Comments
 (0)