This commit is contained in:
2026-04-26 16:08:32 +09:00
parent b2c3e02ccc
commit e3780e2982
3 changed files with 113 additions and 2 deletions
+2 -1
View File
@@ -2,5 +2,6 @@ class IpAddress < ApplicationRecord
validates :ip_address, presence: true, length: { maximum: 16 }
validates :banned, inclusion: { in: [true, false] }
has_many :users
has_many :user_ips, dependent: :destroy
has_many :users, through: :user_ips
end