Include other unique key column in condition in Model\Tag:store
- Address https://github.com/friendica/friendica/issues/12486#issuecomment-1372640002
This commit is contained in:
parent
69a9c2c618
commit
670b518875
|
@ -119,7 +119,7 @@ class Tag
|
|||
$tag = DBA::selectFirst('tag', ['name', 'type'], ['url' => $url]);
|
||||
if (!empty($tag)) {
|
||||
if ($tag['name'] != substr($name, 0, 96)) {
|
||||
DBA::update('tag', ['name' => substr($name, 0, 96)], ['url' => $url]);
|
||||
DBA::update('tag', ['name' => substr($name, 0, 96)], ['url' => $url, 'type' => $tag['type']]);
|
||||
}
|
||||
if (!empty($target) && ($tag['type'] != $target)) {
|
||||
DBA::update('tag', ['type' => $target], ['url' => $url]);
|
||||
|
|
Loading…
Reference in New Issue
Block a user