mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FEATURE: Merge tagging plugin into core
This commit is contained in:
@@ -276,6 +276,18 @@ class Guardian
|
||||
UserExport.where(user_id: @user.id, created_at: (Time.zone.now.beginning_of_day..Time.zone.now.end_of_day)).count == 0
|
||||
end
|
||||
|
||||
def can_create_tag?
|
||||
user && user.has_trust_level?(SiteSetting.min_trust_to_create_tag.to_i)
|
||||
end
|
||||
|
||||
def can_tag_topics?
|
||||
user && user.has_trust_level?(SiteSetting.min_trust_level_to_tag_topics.to_i)
|
||||
end
|
||||
|
||||
def can_admin_tags?
|
||||
is_staff?
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def is_my_own?(obj)
|
||||
|
||||
Reference in New Issue
Block a user