Fix duplicated UUID detection when there are empty uuids

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This commit is contained in:
Côme Chilliet 2022-03-08 11:45:18 +01:00 committed by backportbot[bot]
parent c6e67322fb
commit 1bb981abd6

View file

@ -278,7 +278,7 @@ class Version1130Date20211102154716 extends SimpleMigrationStep {
->having($select->expr()->gt($select->func()->count('owncloud_name'), $select->createNamedParameter(1)));
$result = $select->executeQuery();
while ($uuid = $result->fetchOne()) {
while (($uuid = $result->fetchOne()) !== false) {
yield $uuid;
}
$result->closeCursor();