Merge commit 'c1f398ae93' into kb-draft-15.9-lts

This commit is contained in:
KMY 2025-02-28 09:14:02 +09:00
commit 3eead356e7
207 changed files with 6055 additions and 3148 deletions

View file

@ -147,6 +147,10 @@ class UserRole < ApplicationRecord
other_role.nil? || position > other_role.position
end
def bypass_block?(role)
overrides?(role) && highlighted? && can?(*Flags::CATEGORIES[:moderation])
end
def computed_permissions
# If called on the everyone role, no further computation needed
return permissions if everyone?