GRN2-260: Added the ability to merge user accounts (#938)

* Added the ability to merge user accounts

* Styling fixes
This commit is contained in:
Ahmad Farhat
2020-02-14 10:24:06 -05:00
committed by GitHub
parent 31258272c2
commit 005c738e4d
13 changed files with 222 additions and 5 deletions

View File

@ -60,6 +60,11 @@ class Room < ApplicationRecord
user.rooms.include?(self)
end
# Determines whether room is a home room
def home_room?
owner.main_room == self
end
def shared_users
User.where(id: shared_access.pluck(:user_id))
end