0
0
Fork 0

Add table of contents to about page (#11885)

Move public domain blocks information to about page
This commit is contained in:
Eugen Rochko 2019-09-19 11:09:05 +02:00 committed by GitHub
parent e1066cd431
commit d930eb88b6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 328 additions and 215 deletions

View file

@ -26,6 +26,7 @@ class DomainBlock < ApplicationRecord
scope :matches_domain, ->(value) { where(arel_table[:domain].matches("%#{value}%")) }
scope :with_user_facing_limitations, -> { where(severity: [:silence, :suspend]).or(where(reject_media: true)) }
scope :by_severity, -> { order(Arel.sql('(CASE severity WHEN 0 THEN 1 WHEN 1 THEN 2 WHEN 2 THEN 0 END), reject_media, domain')) }
class << self
def suspend?(domain)