mirror of
https://github.com/friendica/friendica
synced 2025-05-09 22:24:09 +02:00
Switch static::$parameters
to $this->parameters
This commit is contained in:
parent
489cd0884a
commit
5879535822
116 changed files with 321 additions and 314 deletions
|
@ -41,7 +41,7 @@ class ListTimeline extends BaseApi
|
|||
self::checkAllowedScope(self::SCOPE_READ);
|
||||
$uid = self::getCurrentUserID();
|
||||
|
||||
if (empty(static::$parameters['id'])) {
|
||||
if (empty($this->parameters['id'])) {
|
||||
DI::mstdnError()->UnprocessableEntity();
|
||||
}
|
||||
|
||||
|
@ -60,7 +60,7 @@ class ListTimeline extends BaseApi
|
|||
$params = ['order' => ['uri-id' => true], 'limit' => $request['limit']];
|
||||
|
||||
$condition = ["`uid` = ? AND `gravity` IN (?, ?) AND `contact-id` IN (SELECT `contact-id` FROM `group_member` WHERE `gid` = ?)",
|
||||
$uid, GRAVITY_PARENT, GRAVITY_COMMENT, static::$parameters['id']];
|
||||
$uid, GRAVITY_PARENT, GRAVITY_COMMENT, $this->parameters['id']];
|
||||
|
||||
if (!empty($request['max_id'])) {
|
||||
$condition = DBA::mergeConditions($condition, ["`uri-id` < ?", $request['max_id']]);
|
||||
|
|
|
@ -42,7 +42,7 @@ class Tag extends BaseApi
|
|||
self::checkAllowedScope(self::SCOPE_READ);
|
||||
$uid = self::getCurrentUserID();
|
||||
|
||||
if (empty(static::$parameters['hashtag'])) {
|
||||
if (empty($this->parameters['hashtag'])) {
|
||||
DI::mstdnError()->UnprocessableEntity();
|
||||
}
|
||||
|
||||
|
@ -69,7 +69,7 @@ class Tag extends BaseApi
|
|||
|
||||
$condition = ["`name` = ? AND (`uid` = ? OR (`uid` = ? AND NOT `global`))
|
||||
AND (`network` IN (?, ?, ?, ?) OR (`uid` = ? AND `uid` != ?))",
|
||||
static::$parameters['hashtag'], 0, $uid, Protocol::ACTIVITYPUB, Protocol::DFRN, Protocol::DIASPORA, Protocol::OSTATUS, $uid, 0];
|
||||
$this->parameters['hashtag'], 0, $uid, Protocol::ACTIVITYPUB, Protocol::DFRN, Protocol::DIASPORA, Protocol::OSTATUS, $uid, 0];
|
||||
|
||||
if ($request['local']) {
|
||||
$condition = DBA::mergeConditions($condition, ["`uri-id` IN (SELECT `uri-id` FROM `post-user` WHERE `origin`)"]);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue