[various] Address a couple of PHP 8.1 notices
- Replace a couple of strstr calls by strpos - Address part of https://github.com/friendica/friendica/issues/12011#issuecomment-1331012289
This commit is contained in:
parent
666d559e72
commit
2e4e7befe5
|
@ -126,7 +126,7 @@ function dwpost_send(App $a, array &$b)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!strstr($b['postopts'],'dwpost')) {
|
if (strpos($b['postopts'] ?? '', 'dwpost') === false) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -366,7 +366,7 @@ function statusnet_hook_fork(App $a, array &$b)
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// Comments are never exported when we don't import the GNU Social timeline
|
// Comments are never exported when we don't import the GNU Social timeline
|
||||||
if (!strstr($post['postopts'], 'statusnet') || ($post['parent'] != $post['id']) || $post['private']) {
|
if (strpos($post['postopts'] ?? '', 'statusnet') === false || ($post['parent'] != $post['id']) || $post['private']) {
|
||||||
$b['execute'] = false;
|
$b['execute'] = false;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user