mirror of
https://github.com/friendica/friendica
synced 2025-04-28 12:24:23 +02:00
Issue-4816: Avoid SQL errors / Unarchive living relais servers
This commit is contained in:
parent
9d5abaca1c
commit
75f97db4ec
2 changed files with 12 additions and 1 deletions
|
@ -1418,7 +1418,13 @@ class PortableContact
|
|||
|
||||
dba::delete('gserver-tag', ['gserver-id' => $gserver['id']]);
|
||||
if ($data->scope == 'tags') {
|
||||
// Avoid duplicates
|
||||
$tags = [];
|
||||
foreach ($data->tags as $tag) {
|
||||
$tags[$tag] = $tag;
|
||||
}
|
||||
|
||||
foreach ($tags as $tag) {
|
||||
dba::insert('gserver-tag', ['gserver-id' => $gserver['id'], 'tag' => $tag]);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue