lib/rsqoot/logger.rb in rsqoot-0.5.5 vs lib/rsqoot/logger.rb in rsqoot-0.5.6

- old
+ new

@@ -3,11 +3,11 @@ # Add logger support, easy for log monitor when running your app # Output errors and valid records count # TODO add color support # - def logger(options = {records: [], uri: '', error: '', type: '', opts: {}}) + def logger(options = { records: [], uri: '', error: '', type: '', opts: {} }) records = options[:records].nil? ? [] : options[:records] error = options[:error] uri = options[:uri] type = options[:type] opts = options[:opts] @@ -22,22 +22,22 @@ Rails.logger.info ">>> Hit #{records.count} records" end else if error.present? puts ">>> Error: #{error}" - puts "" + puts '' else puts ">>> Querying Sqoot API V2: #{type}" - puts "" + puts '' puts ">>> #{uri}" - puts "" + puts '' puts ">>> #{opts}" - puts "" + puts '' puts ">>> Hit #{records.count} records" - puts "" + puts '' end end end module_function :logger end -end \ No newline at end of file +end