Module: Emotions::Emotive
- Extended by:
- ActiveSupport::Concern
- Defined in:
- lib/emotions/emotive.rb
Defined Under Namespace
Modules: ClassMethods
Instance Method Summary collapse
Instance Method Details
#update_emotion_counter(emotion) ⇒ Object
14 15 16 17 18 19 20 |
# File 'lib/emotions/emotive.rb', line 14 def update_emotion_counter(emotion) attribute = "#{emotion}_emotions_count" if respond_to?(attribute) update_attribute(attribute, send("#{emotion}_about").count) end end |