Fixes Issue 5276 and an endless loop in item::update

This commit is contained in:
Michael 2018-06-23 10:32:53 +00:00
parent 585ba4c09f
commit a7d2f126eb
2 changed files with 16 additions and 51 deletions

View file

@ -115,7 +115,8 @@ class Term
$users = q("SELECT `uid` FROM `contact` WHERE self AND (`url` = '%s' OR `nurl` = '%s')", $link, $link);
foreach ($users AS $user) {
if ($user['uid'] == $message['uid']) {
Item::update(['mention' => true], ['id' => $itemid]);
/// @todo This function is called frim Item::update - so we mustn't call that function here
dba::update('item', ['mention' => true], ['id' => $itemid]);
dba::update('thread', ['mention' => true], ['iid' => $message['parent']]);
}
}