mirror of
https://github.com/friendica/friendica
synced 2025-05-13 13:04:13 +02:00
Issue 13845: Support "sensitive" attribute
This commit is contained in:
parent
d9d42105d6
commit
15df9990da
11 changed files with 53 additions and 28 deletions
|
@ -378,6 +378,18 @@ class Tag
|
|||
return DBA::exists('post-tag', ['uri-id' => $uriId, 'type' => [self::HASHTAG, self::MENTION, self::EXCLUSIVE_MENTION, self::IMPLICIT_MENTION]]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check for a given hashtag on a given post
|
||||
*
|
||||
* @param integer $uriId
|
||||
* @param string $tag
|
||||
* @return boolean
|
||||
*/
|
||||
public static function existsTagForPost(int $uriId, string $tag): bool
|
||||
{
|
||||
return DBA::exists('tag-view', ['uri-id' => $uriId, 'type' => self::HASHTAG, 'name' => $tag]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove tag/mention
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue