mirror of
https://github.com/yingziwu/mastodon.git
synced 2026-02-24 19:22:41 +00:00
Add explicit dependent: nil to associations (#28169)
This commit is contained in:
parent
1564799952
commit
f70f39dd04
10 changed files with 20 additions and 30 deletions
|
|
@ -20,7 +20,7 @@ class Invite < ApplicationRecord
|
|||
include Expireable
|
||||
|
||||
belongs_to :user, inverse_of: :invites
|
||||
has_many :users, inverse_of: :invite
|
||||
has_many :users, inverse_of: :invite, dependent: nil
|
||||
|
||||
scope :available, -> { where(expires_at: nil).or(where('expires_at >= ?', Time.now.utc)) }
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue