-
Notifications
You must be signed in to change notification settings - Fork 299
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Global minorversion #518
base: master
Are you sure you want to change the base?
Global minorversion #518
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh noticed a few more we can whack
lib/quickbooks/service/customer.rb
Outdated
@@ -9,17 +9,16 @@ def delete(customer) | |||
|
|||
def url_for_resource(resource) | |||
url = super(resource) | |||
"#{url}?minorversion=#{Quickbooks::Model::Customer::MINORVERSION}" | |||
url | |||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this one seems like it could go too right?
lib/quickbooks/service/invoice.rb
Outdated
@@ -7,17 +7,16 @@ def delete(invoice) | |||
end | |||
|
|||
def url_for_resource(resource) | |||
url = super(resource) | |||
super(resource) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This too?
lib/quickbooks/service/invoice.rb
Outdated
fetch_object(model, url, params) | ||
end | ||
|
||
def url_for_query(query = nil, start_position = 1, max_results = 20, options = {}) | ||
url = super(query, start_position, max_results, options) | ||
"#{url}&minorversion=#{Quickbooks::Model::Invoice::MINORVERSION}" | ||
super(query, start_position, max_results, options) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and this?
lib/quickbooks/service/customer.rb
Outdated
fetch_object(model, url, params) | ||
end | ||
|
||
def url_for_query(query = nil, start_position = 1, max_results = 20, options = {}) | ||
url = super(query, start_position, max_results, options) | ||
"#{url}&minorversion=#{Quickbooks::Model::Customer::MINORVERSION}" | ||
super(query, start_position, max_results, options) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this too?
Do we have to worry about setting the global version introducing breaking changes? Like if I'm upgrading do I want to lock this at a lower version? |
Good question, I wondered about that too. From what I can tell QBO uses minorversions on data reads, potentially returning more info than before. I have yet to see if alter the format / payload depending on a version change. In other words, bumping the minorversion tells QBO to return additional data than before (e.g. Thus, I think it should be safe to use and not introduce backwards incompatibilities? |
That makes sense. It kind of an interesting versioning strategy if only adds additions. Typically versions are used to introduce breaking changes... so glad they haven't had to do that I guess? |
No description provided.