module ShoutOut

Constants

VERSION

Public Instance Methods

shout(action, record) click to toggle source
# File lib/shout_out.rb, line 31
def shout(action, record)
  begin
    klass = "#{record.class.model_name}Shout".constantize
  rescue NameError
    return
  end

  klass.new(record).try(action)
end