lib/backup/notifier/campfire.rb in backup_zh-4.0.3.1 vs lib/backup/notifier/campfire.rb in backup_zh-4.2.0

- old
+ new

@@ -40,16 +40,10 @@ # `:failure` # : The backup operation failed. # : Notification will be sent if `on_warning` or `on_success` is `true`. # def notify!(status) - tag = case status - when :success then '[Backup::Success]' - when :warning then '[Backup::Warning]' - when :failure then '[Backup::Failure]' - end - message = "#{ tag } #{ model.label } (#{ model.trigger })" - send_message(message) + send_message(message.call(model, :status => status_data_for(status))) end def send_message(message) uri = "https://#{ subdomain }.campfirenow.com/room/#{ room_id }/speak.json" options = {