fix use of executeQuery and -Statement

Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
pull/31115/head
Arthur Schiwon 2022-02-10 23:13:06 +07:00
parent be7feb7e3b
commit 37a5a266df
No known key found for this signature in database
GPG Key ID: 7424F1874854DF23
2 changed files with 4 additions and 4 deletions

@ -343,7 +343,7 @@ abstract class AbstractMapping {
$select->where($select->expr()->like('directory_uuid', $select->createNamedParameter('invalidated_%')));
}
$result = $select->executeQuery();
$result = $select->execute();
$entries = $result->fetchAll();
$result->closeCursor();

@ -216,7 +216,7 @@ class Version1130Date20211102154716 extends SimpleMigrationStep {
$update->setParameter('nextcloudId', $nextcloudId);
$update->setParameter('invalidatedUuid', 'invalidated_' . \bin2hex(\random_bytes(6)));
try {
$update->executeStatement();
$update->execute();
$this->logger->warning(
'LDAP user or group with ID {nid} has a duplicated UUID value which therefore was invalidated. You may double-check your LDAP configuration and trigger an update of the UUID.',
[
@ -247,7 +247,7 @@ class Version1130Date20211102154716 extends SimpleMigrationStep {
->from($table)
->where($select->expr()->eq('directory_uuid', $select->createNamedParameter($uuid)));
$result = $select->executeQuery();
$result = $select->execute();
$idList = [];
while ($id = $result->fetchOne()) {
$idList[] = $id;
@ -267,7 +267,7 @@ class Version1130Date20211102154716 extends SimpleMigrationStep {
->groupBy('directory_uuid')
->having($select->expr()->gt($select->func()->count('owncloud_name'), $select->createNamedParameter(1)));
$result = $select->executeQuery();
$result = $select->execute();
while ($uuid = $result->fetchOne()) {
yield $uuid;
}