From a5dc5ce921b44e6d4278f2bd2efb3e29feb2d6e8 Mon Sep 17 00:00:00 2001 From: Rick Barrette Date: Thu, 28 Jul 2016 19:42:09 -0400 Subject: [PATCH] Update qbo.rb --- app/models/qbo.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/app/models/qbo.rb b/app/models/qbo.rb index df08b24..9cdabfc 100644 --- a/app/models/qbo.rb +++ b/app/models/qbo.rb @@ -11,7 +11,10 @@ class Qbo < ActiveRecord::Base unloadable validates_presence_of :qb_token, :qb_secret, :company_id, :token_expires_at, :reconnect_token_at - + + OAUTH_CONSUMER_KEY = Setting.plugin_redmine_qbo['settingsOAuthConsumerKey'] + OAUTH_CONSUMER_SECRET = Setting.plugin_redmine_qbo['settingsOAuthConsumerSecret'] + # Configure quickbooks-ruby-base to access our database Quickbooks::Base.configure do |c| c.persistent_token = 'qb_token' @@ -20,9 +23,6 @@ class Qbo < ActiveRecord::Base end def self.get_oauth_consumer - OAUTH_CONSUMER_KEY = Setting.plugin_redmine_qbo['settingsOAuthConsumerKey'] - OAUTH_CONSUMER_SECRET = Setting.plugin_redmine_qbo['settingsOAuthConsumerSecret'] - # Quickbooks Config Info return OAuth::Consumer.new(OAUTH_CONSUMER_KEY, OAUTH_CONSUMER_SECRET, { :site => "https://oauth.intuit.com",