1
0
Fork 0

Reorder code

This commit is contained in:
Alex Kotov 2019-03-24 19:09:16 +05:00
parent f4b9f372d2
commit f93141d0f4
Signed by: kotovalexarian
GPG Key ID: 553C0EBBEB5D5F08
1 changed files with 6 additions and 6 deletions

View File

@ -12,6 +12,12 @@ class Account < ApplicationRecord
self.adapter = Rolify::Adapter::Base.create 'role_adapter', role_cname, name self.adapter = Rolify::Adapter::Base.create 'role_adapter', role_cname, name
##########
# Scopes #
##########
scope :guests, -> { includes(:user).where(users: { id: nil }) }
################ ################
# Associations # # Associations #
################ ################
@ -38,12 +44,6 @@ class Account < ApplicationRecord
has_many :passport_confirmations, dependent: :restrict_with_exception has_many :passport_confirmations, dependent: :restrict_with_exception
##########
# Scopes #
##########
scope :guests, -> { includes(:user).where(users: { id: nil }) }
############# #############
# Callbacks # # Callbacks #
############# #############