Skip to content

Commit

Permalink
Merge pull request #29074 from nextcloud/bug/noid/no-execute-query-in-21
Browse files Browse the repository at this point in the history
[stable21] executeQuery and executeStatement are 22+
  • Loading branch information
kesselb authored Oct 6, 2021
2 parents 308b48a + 670a2d5 commit edad252
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ protected function handleIDs(string $table, bool $emitHooks) {
$q = $this->getSelectQuery($table);
$u = $this->getUpdateQuery($table);

$r = $q->executeQuery();
$r = $q->execute();
while ($row = $r->fetch()) {
$newId = hash('sha256', $row['owncloud_name'], false);
if ($emitHooks) {
Expand All @@ -82,7 +82,7 @@ protected function handleIDs(string $table, bool $emitHooks) {
$u->setParameter('uuid', $row['directory_uuid']);
$u->setParameter('newId', $newId);
try {
$u->executeStatement();
$u->execute();
if ($emitHooks) {
$this->emitUnassign($row['owncloud_name'], false);
$this->emitAssign($newId);
Expand Down

0 comments on commit edad252

Please sign in to comment.