Move OTYPE constants to own enum class

This commit is contained in:
nupplaPhil 2020-02-04 22:01:55 +01:00
parent e42b843505
commit 97b6f6b3b3
No known key found for this signature in database
GPG key ID: D8365C3D36B77D90
4 changed files with 16 additions and 6 deletions

View file

@ -5906,7 +5906,7 @@ function api_friendica_notification_seen($type)
$notify = DI::notify()->getByID($id);
DI::notify()->setSeen(true, $notify);
if ($notify->otype === Notify::OTYPE_ITEM) {
if ($notify->otype === Notify\ObjectType::ITEM) {
$item = Item::selectFirstForUser(api_user(), [], ['id' => $notify->iid, 'uid' => api_user()]);
if (DBA::isResult($item)) {
// we found the item, return it to the user