Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

wiredump

  • Loading branch information...
commit fdbccaffad5b07d04696c5081a437b75af144925 1 parent 52ae76e
@yeah yeah authored
View
2  init.rb
@@ -6,7 +6,7 @@
FACEBOOKER = Facebooker.load_configuration(facebook_config)
# enable logger before including everything else, in case we ever want to log initialization
-Facebooker.logger = RAILS_DEFAULT_LOGGER if Object.const_defined? :RAILS_DEFAULT_LOGGER
+Facebooker.logger = Rails.logger
require 'net/http_multipart_post'
if defined? Rails
View
2  lib/facebooker/rails/publisher.rb
@@ -433,7 +433,7 @@ def send_message(method)
# nodoc
# needed for actionview
def logger
- RAILS_DEFAULT_LOGGER
+ Rails.logger
end
# nodoc
View
2  lib/facebooker/railtie.rb
@@ -28,7 +28,7 @@ module Facebooker::Rails; end
initializer 'facebooker.set_logger' do |app|
# enable logger before including everything else, in case we ever want to log initialization
- Facebooker.logger = RAILS_DEFAULT_LOGGER if Object.const_defined? :RAILS_DEFAULT_LOGGER
+ Facebooker.logger = Rails.logger
end
end
end
View
8 lib/facebooker/service.rb
@@ -64,7 +64,13 @@ def self.process_async
def post(params)
attempt = 0
if active_service.parse_results?
- Parser.parse(params[:method], post_form(url,params) )
+ results = post_form(url,params)
+ unless Facebooker::Logging::skip_api_logging
+ Facebooker::Logging.log_info 'Request url', url
+ Facebooker::Logging.log_info 'Request params', params.to_yaml
+ Facebooker::Logging.log_info 'Response', results.to_yaml
+ end
+ Parser.parse(params[:method], results)
else
post_form(url,params)
end
View
1  rails/init.rb
@@ -1 +0,0 @@
-require File.join(File.dirname(__FILE__),'../init.rb')
Please sign in to comment.
Something went wrong with that request. Please try again.