mirror of
https://github.com/friendica/friendica
synced 2025-04-20 17:50:12 +00:00
Use "checkAllowedScope" instead of "login"
This commit is contained in:
parent
5853fe562d
commit
2a440c0bae
54 changed files with 62 additions and 73 deletions
|
@ -32,7 +32,7 @@ class Clear extends BaseApi
|
|||
{
|
||||
public static function post(array $parameters = [])
|
||||
{
|
||||
self::login(self::SCOPE_WRITE);
|
||||
self::checkAllowedScope(self::SCOPE_WRITE);
|
||||
$uid = self::getCurrentUserID();
|
||||
|
||||
DBA::update('notification', ['seen' => true], ['uid' => $uid]);
|
||||
|
|
|
@ -33,7 +33,7 @@ class Dismiss extends BaseApi
|
|||
{
|
||||
public static function post(array $parameters = [])
|
||||
{
|
||||
self::login(self::SCOPE_WRITE);
|
||||
self::checkAllowedScope(self::SCOPE_WRITE);
|
||||
$uid = self::getCurrentUserID();
|
||||
|
||||
if (empty($parameters['id'])) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue