Update qbo_controller.rb

This commit is contained in:
2020-01-04 22:46:20 -05:00
committed by GitHub
parent fb47eaba0e
commit 0364989fe1

View File

@@ -1,6 +1,6 @@
#The MIT License (MIT)
#
#Copyright (c) 2017 rick barrette
#Copyright (c) 2020 rick barrette
#
#Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
#
@@ -66,7 +66,7 @@ class QboController < ApplicationController
qbo.company_id = params[:realmId]
access_token = OAuth2::AccessToken.new(oauth2_client, resp.token, refresh_token: resp.refresh_token)
qbo.token = access_token
qbo.token = access_token.to_hash
qbo.expire = 1.hour.from_now.utc
if qbo.save!