diff --git a/app/models/user_ban.rb b/app/models/user_ban.rb deleted file mode 100644 index 65ee8df3..00000000 --- a/app/models/user_ban.rb +++ /dev/null @@ -1,14 +0,0 @@ -class UserBan < ApplicationRecord - belongs_to :user - belongs_to :banned_by, class_name: "User", optional: true - - scope :current, -> { where("expires_at IS NULL or expires_at > NOW()") } - - def permanent? - expires_at.nil? - end - - def current? - permanent? || expires_at > Time.now.utc - end -end