Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fixed nil status nomethoderror

  • Loading branch information...
commit 6d28f0ad8274712b884a43dad3842ebd93ff95d9 1 parent 6ec33a5
@jamesmacaulay authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  backfire.rb
View
2  backfire.rb
@@ -71,7 +71,7 @@ def self.update_campfire
user_statuses, user_entries = user_array.last.partition {|item| item.is_a? Status}
status = user_statuses.first
user_entries = user_entries.sort {|a,b| b.updated_at <=> a.updated_at }
- latest_updated_at = status.updated_at if status.updated_at > latest_updated_at
+ latest_updated_at = status.updated_at if status.updated_at and status.updated_at > latest_updated_at
latest_updated_at = user_entries.first.updated_at if user_entries.first and user_entries.first.updated_at > latest_updated_at
unless user_entries.empty? and (self.last_updated_at ? status.updated_at < self.last_updated_at : true)
update << "\n#{user.name}: #{status.message unless user_statuses.empty?}\n"
Please sign in to comment.
Something went wrong with that request. Please try again.