Class: UserMention

Inherits:
ApplicationRecord show all
Defined in:
app/models/user_mention.rb

Instance Method Summary collapse

Methods inherited from ApplicationRecord

at_most, id_in, id_not_in, iid_in, pluck_primary_key, primary_key_in, safe_ensure_unique, safe_find_or_create_by, safe_find_or_create_by!, underscore, without_order

Instance Method Details

#has_mentions?Boolean

Returns:

  • (Boolean)

6
7
8
# File 'app/models/user_mention.rb', line 6

def has_mentions?
  mentioned_users_ids.present? || mentioned_groups_ids.present? || mentioned_projects_ids.present?
end