Merge pull request #13507 from nextcloud/backport/13503/stable14
[stable14] RemoveClassifiedEventActivity: check if calendar still exists
This commit is contained in:
commit
6f0d248be9
|
@ -75,6 +75,10 @@ class RemoveClassifiedEventActivity implements IRepairStep {
|
||||||
$result = $query->execute();
|
$result = $query->execute();
|
||||||
|
|
||||||
while ($row = $result->fetch()) {
|
while ($row = $result->fetch()) {
|
||||||
|
if ($row['principaluri'] === null) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
$delete->setParameter('owner', $this->getPrincipal($row['principaluri']))
|
$delete->setParameter('owner', $this->getPrincipal($row['principaluri']))
|
||||||
->setParameter('type', 'calendar')
|
->setParameter('type', 'calendar')
|
||||||
->setParameter('calendar_id', $row['calendarid'])
|
->setParameter('calendar_id', $row['calendarid'])
|
||||||
|
@ -105,6 +109,10 @@ class RemoveClassifiedEventActivity implements IRepairStep {
|
||||||
$result = $query->execute();
|
$result = $query->execute();
|
||||||
|
|
||||||
while ($row = $result->fetch()) {
|
while ($row = $result->fetch()) {
|
||||||
|
if ($row['principaluri'] === null) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
$delete->setParameter('owner', $this->getPrincipal($row['principaluri']))
|
$delete->setParameter('owner', $this->getPrincipal($row['principaluri']))
|
||||||
->setParameter('type', 'calendar')
|
->setParameter('type', 'calendar')
|
||||||
->setParameter('calendar_id', $row['calendarid'])
|
->setParameter('calendar_id', $row['calendarid'])
|
||||||
|
|
Loading…
Reference in New Issue