Skip to content
Snippets Groups Projects
Unverified Commit e36924e3 authored by Morris Jobke's avatar Morris Jobke Committed by GitHub
Browse files

Merge pull request #12439 from nextcloud/vcard_uid_repair_postgres

Fix SetVcardDatabaseUID when using postgresql
parents 5e848248 e1a49a22
No related branches found
No related tags found
No related merge requests found
...@@ -112,7 +112,11 @@ class SetVcardDatabaseUID implements IRepairStep { ...@@ -112,7 +112,11 @@ class SetVcardDatabaseUID implements IRepairStep {
$count = 0; $count = 0;
foreach ($entries as $entry) { foreach ($entries as $entry) {
$count++; $count++;
$uid = $this->getUID($entry['carddata']); $cardData = $entry['carddata'];
if (is_resource($cardData)) {
$cardData = stream_get_contents($cardData);
}
$uid = $this->getUID($cardData);
$this->update($entry['id'], $uid); $this->update($entry['id'], $uid);
} }
$this->connection->commit(); $this->connection->commit();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment