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

[stable21] Add repair job to delete calendar subscriptions that were orphaned when deleting an user #30006

Closed
wants to merge 2 commits into from

Conversation

backportbot-nextcloud[bot]
Copy link

@backportbot-nextcloud backportbot-nextcloud bot commented Dec 1, 2021

backport of #28716

@backportbot-nextcloud backportbot-nextcloud bot added this to the Nextcloud 21.0.8 milestone Dec 1, 2021
@tcitworld tcitworld added the feature: caldav Related to CalDAV internals label Dec 17, 2021
This was referenced Jan 7, 2022
@skjnldsv skjnldsv added the 2. developing Work in progress label Jan 7, 2022
@MichaIng

This comment has been minimized.

@MichaIng MichaIng added 3. to review Waiting for reviews and removed 2. developing Work in progress labels Jan 14, 2022
@skjnldsv skjnldsv mentioned this pull request Jan 20, 2022
9 tasks
@skjnldsv skjnldsv requested review from MichaIng, a team, PVince81, icewind1991 and skjnldsv and removed request for a team January 20, 2022 09:41
@skjnldsv skjnldsv mentioned this pull request Jan 25, 2022
8 tasks
@blizzz
Copy link
Member

blizzz commented Feb 11, 2022

still waiting for a second review

@blizzz blizzz added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels Feb 14, 2022
$qb = $this->connection->getQueryBuilder();
$qb->delete('calendarsubscriptions')
->where($qb->expr()->eq('id', $qb->createNamedParameter($orphanSubscriptionID)))
->executeStatement();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

only available from NC 22

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
->executeStatement();
->execute();

$qb->method('createNamedParameter')->willReturn($this->createMock(IParameter::class));
$qb->method('where')->willReturn($qb);
// Only when user exists
$qb->expects($this->exactly($deletions))->method('executeStatement');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
$qb->expects($this->exactly($deletions))->method('executeStatement');
$qb->expects($this->exactly($deletions))->method('execute');

@MichaIng MichaIng added 2. developing Work in progress and removed 4. to release Ready to be released and/or waiting for tests to finish labels Feb 14, 2022
tcitworld and others added 2 commits February 15, 2022 00:36
deleteding an user

Follow-up to #28419

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
@blizzz blizzz closed this Mar 21, 2022
@ChristophWurst ChristophWurst deleted the backport/28716/stable21 branch March 21, 2022 15:15
@ChristophWurst
Copy link
Member

We decided it isn't worth the risk backporting this change.

@MichaIng MichaIng removed this from the Nextcloud 21.0.10 milestone Mar 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2. developing Work in progress bug feature: caldav Related to CalDAV internals feature: dav
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants