Skip to content
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

fix(dav) Handle Calendar trashbin UID conflicts by removing the deleted calendar object #34375

Merged
merged 1 commit into from
Feb 21, 2023

Conversation

miaulalala
Copy link
Contributor

@miaulalala miaulalala commented Oct 2, 2022

... before re- importing the calendar event.

Fixes #30096

@miaulalala miaulalala added bug 2. developing Work in progress feature: caldav Related to CalDAV internals labels Oct 2, 2022
@miaulalala miaulalala self-assigned this Oct 2, 2022
if ($found !== false) {
// when importing a calendar obejct already previously imported
// we first restore it and then update the event to the new data
$this->restoreCalendarObject($result['calendardata']);

Check failure

Code scanning / Psalm

UndefinedInterfaceMethod

Method OCP\DB\IResult::offsetGet does not exist
@miaulalala
Copy link
Contributor Author

/rebase

@miaulalala miaulalala force-pushed the fix/trashbin-uid branch 2 times, most recently from ce7e021 to 17b6613 Compare February 8, 2023 12:46
@miaulalala miaulalala changed the title WIP: fix Calendar Trashbin (fix) Calendar trashbin UID conflicts Feb 8, 2023
@miaulalala miaulalala marked this pull request as ready for review February 8, 2023 12:47
@tcitworld
Copy link
Member

A better commit title please? :)

@miaulalala miaulalala changed the title (fix) Calendar trashbin UID conflicts fix(dav) Handle Calendar trashbin UID conflicts by removing the deleted calendar object Feb 8, 2023
Signed-off-by: Anna Larch <anna@nextcloud.com>
@miaulalala
Copy link
Contributor Author

Drone failure is apps file sharing as usual

@miaulalala miaulalala added 3. to review Waiting for reviews and removed 2. developing Work in progress labels Feb 20, 2023
@ChristophWurst
Copy link
Member

/backport to stable25

@ChristophWurst
Copy link
Member

/backport to stable24

@tamas646
Copy link

tamas646 commented Apr 4, 2023

Shouldn't we make a fix for the delete function as well?

Now I get error messages on deletion: A calendar object with URI <uri>.ics already exists in calendar <n>, therefore this object can't be moved into the trashbin (#30096 (comment))

Update: Sorry, I most probably misunderstood the code.
Created issue #37577

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews bug feature: caldav Related to CalDAV internals
Projects
None yet
8 participants