b0deafc53e
* all the good changes * follows * dont send duplicates * remove follow_type for now * dont add all the extra stuff we're not implementing yet * refactor * lots of fixes * Delete activity.html.erb * Delete activity.text.erb * Update 20170209215819_create_follows.rb * Update schema.rb * Update mapping.rb * Update mailboxer.rb
12 lines
No EOL
315 B
Ruby
12 lines
No EOL
315 B
Ruby
# frozen_string_literal: true
|
|
class FollowReason < ApplicationRecord
|
|
REASONS = %w(created commented contributed followed shared_on starred).freeze
|
|
|
|
belongs_to :follow
|
|
|
|
validates :follow, presence: true
|
|
|
|
def has_reason
|
|
created || commented || contributed || followed || shared_on || starred
|
|
end
|
|
end |