Module: Thredded::UserPermissions::Moderate::IfModeratorColumnTrue

Extended by:
ActiveSupport::Concern
Included in:
Thredded::UserExtender
Defined in:
app/models/thredded/user_permissions/moderate/if_moderator_column_true.rb

Instance Method Summary collapse

Instance Method Details

#thredded_can_moderate_messageboardsActiveRecord::Relation<Thredded::Messageboard>

Returns messageboards that the user can moderate.

Returns:



10
11
12
# File 'app/models/thredded/user_permissions/moderate/if_moderator_column_true.rb', line 10

def thredded_can_moderate_messageboards
  send(Thredded.moderator_column) ? Thredded::Messageboard.all : Thredded::Messageboard.none
end