Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge pull request #46 from vinted/fix_puts_ignoring_logging

Fix: one of the `puts` was ignoring @@logging flag
  • Loading branch information...
commit 7490ea0a89c855f80fb2e1cc4791a31fd7aa0364 2 parents a0138f5 + ba8bd00
@treeder treeder authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  lib/mini_fb.rb
View
2  lib/mini_fb.rb
@@ -694,7 +694,7 @@ def self.fetch(url, options={})
return res_hash
rescue RestClient::Exception => ex
- puts "ex.http_code=" + ex.http_code.to_s
+ puts "ex.http_code=" + ex.http_code.to_s if @@logging
puts 'ex.http_body=' + ex.http_body if @@logging
res_hash = JSON.parse(ex.http_body) # probably should ensure it has a good response
raise MiniFB::FaceBookError.new(ex.http_code, "#{res_hash["error"]["type"]}: #{res_hash["error"]["message"]}")
Please sign in to comment.
Something went wrong with that request. Please try again.