tasks/mashery.thor in mashery-0.0.11 vs tasks/mashery.thor in mashery-0.1.0
- old
+ new
@@ -22,11 +22,12 @@
raise Exception, "Please set the MASHERY_SITE_ID environment variable."
key = ENV['MASHERY_API_KEY'] or
raise Exception, "Please set the MASHERY_API_KEY environment variable."
secret = ENV['MASHERY_SHARED_SECRET'] or
raise Exception, "Please set the MASHERY_SHARED_SECRET environment variable."
- ::Mashery.client = ::Mashery::Client.new(site_id, key, secret)
+ ::Mashery.test_mode = ENV['MASHERY_PRODUCTION_MODE'].blank?
::Mashery.logger.level = Logger::DEBUG
+ ::Mashery.client = ::Mashery::Client.new(site_id, key, secret)
begin
yield
rescue ::Mashery::JsonRpcException => e
error(e.message)
rescue ::Mashery::ValidationException => e