lib/bluepill/process_statistics.rb in bluepill-0.0.68 vs lib/bluepill/process_statistics.rb in bluepill-0.0.69

- old
+ new

@@ -1,9 +1,8 @@ -# -*- encoding: utf-8 -*- module Bluepill class ProcessStatistics - STRFTIME = "%m/%d/%Y %H:%I:%S".freeze + STRFTIME = '%m/%d/%Y %H:%I:%S'.freeze EVENTS_TO_PERSIST = 10 attr_reader :events # possibly persist this data. @@ -15,13 +14,12 @@ events.push([event, reason, Time.now]) end def to_s str = events.reverse.map do |(event, reason, time)| - " #{event} at #{time.strftime(STRFTIME)} - #{reason || "unspecified"}" + " #{event} at #{time.strftime(STRFTIME)} - #{reason || 'unspecified'}" end.join("\n") "event history:\n#{str}" end end end -