Skip to content

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

Merged
kesselb merged 1 commit into
masterfrom
fix/trashbin-uid
Feb 21, 2023
Merged

fix(dav) Handle Calendar trashbin UID conflicts by removing the deleted calendar object#34375
kesselb merged 1 commit into
masterfrom
fix/trashbin-uid

Conversation

@miaulalala

@miaulalalamiaulalala commented Oct 2, 2022

Copy link
Copy Markdown
Contributor

... before re- importing the calendar event.

Fixes#30096

@miaulalalamiaulalala added bug 2. developing Work in progress feature: caldav Related to CalDAV internals labels Oct 2, 2022
@miaulalalamiaulalala 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
Copy Markdown
ContributorAuthor

/rebase

@miaulalala
miaulalalaforce-pushed the fix/trashbin-uid branch 2 times, most recently from ce7e021 to 17b6613CompareFebruary 8, 2023 12:46
@miaulalalamiaulalala changed the title WIP: fix Calendar Trashbin(fix) Calendar trashbin UID conflictsFeb 8, 2023
@miaulalala
miaulalala marked this pull request as ready for review February 8, 2023 12:47
@tcitworld

Copy link
Copy Markdown
Member

A better commit title please? :)

@miaulalalamiaulalala changed the title (fix) Calendar trashbin UID conflictsfix(dav) Handle Calendar trashbin UID conflicts by removing the deleted calendar objectFeb 8, 2023
Signed-off-by: Anna Larch <anna@nextcloud.com>
@miaulalala

Copy link
Copy Markdown
ContributorAuthor

Drone failure is apps file sharing as usual

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

Copy link
Copy Markdown
Member

/backport to stable25

@ChristophWurst

Copy link
Copy Markdown
Member

/backport to stable24

@tamas646

tamas646 commented Apr 4, 2023

Copy link
Copy Markdown

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 freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to reviewWaiting for reviewsbugfeature: caldavRelated to CalDAV internals

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Regression: Re-adding Deleted Calendar Events Impossible (Caused by Calendar Trashbin) (with Proposed Solution Suggestion)

9 participants

@miaulalala@tcitworld@ChristophWurst@tamas646@st3iny@artonge@github-advanced-security@kesselb@szaimen