Fixes the missing refresh after ignoring or unignoring a thread (#5614)
* Fixes the missing refresh after ignoring or unignoring a thread * Use numeric values to make the JSON output happy
This commit is contained in:
parent
a8b74e6bc7
commit
ffd2014257
1 changed files with 2 additions and 5 deletions
|
@ -7,8 +7,6 @@ use Friendica\Model\Item;
|
||||||
|
|
||||||
function ignored_init(App $a)
|
function ignored_init(App $a)
|
||||||
{
|
{
|
||||||
$ignored = 0;
|
|
||||||
|
|
||||||
if (!local_user()) {
|
if (!local_user()) {
|
||||||
killme();
|
killme();
|
||||||
}
|
}
|
||||||
|
@ -26,9 +24,8 @@ function ignored_init(App $a)
|
||||||
killme();
|
killme();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$thread['ignored']) {
|
// Numeric values are needed for the json output further below
|
||||||
$ignored = true;
|
$ignored = ($thread['ignored'] ? 0 : 1);
|
||||||
}
|
|
||||||
|
|
||||||
if ($thread['uid'] != 0) {
|
if ($thread['uid'] != 0) {
|
||||||
DBA::update('thread', ['ignored' => $ignored], ['iid' => $message_id]);
|
DBA::update('thread', ['ignored' => $ignored], ['iid' => $message_id]);
|
||||||
|
|
Loading…
Reference in a new issue