Fix tests after the removal of memberships
This commit is contained in:
committed by
Mike Dalessio
parent
8fa9566c07
commit
34d83aaa7c
+10
-2
@@ -7,8 +7,16 @@ class Current < ActiveSupport::CurrentAttributes
|
||||
def session=(value)
|
||||
super(value)
|
||||
|
||||
if value.present? && Current.account.present?
|
||||
self.user = identity.users.find_by(account: Current.account)
|
||||
if value.present? && account.present?
|
||||
self.user = identity.users.find_by(account: account)
|
||||
end
|
||||
end
|
||||
|
||||
def account=(value)
|
||||
super(value)
|
||||
|
||||
if value.present? && identity.present?
|
||||
self.user = identity.users.find_by(account: value)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user