Repository navigation
[documentcollector] Code generation: update services and models - #402
AdyenAutomationBot wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces the DocumentCollector service and its associated DocumentsApi class to support uploading cross-border invoices. A critical issue was identified in DocumentsApi where the DEFAULT_VERSION constant is referenced but not defined, which will lead to a NameError at runtime.
| attr_accessor :service, :version | ||
|
|
||
| def initialize(client, version = DEFAULT_VERSION) | ||
| super(client, version, 'DocumentCollector') | ||
| end |
There was a problem hiding this comment.
The constant DEFAULT_VERSION is referenced as a default argument in DocumentsApi#initialize, but it is not defined within the DocumentsApi class or its parent Service class. This will result in a NameError: uninitialized constant Adyen::DocumentsApi::DEFAULT_VERSION at runtime if DocumentsApi.new is called without explicitly passing a version.
To fix this, define DEFAULT_VERSION = 1 inside the DocumentsApi class, matching the default version of the service.
attr_accessor :service, :version
DEFAULT_VERSION = 1
def initialize(client, version = DEFAULT_VERSION)
super(client, version, 'DocumentCollector')
end56b8c81 to
51f2e6e
Compare
9ca8478 to
7c911e6
Compare
b3e34a6 to
4cc9c88
Compare
4cc9c88 to
a51d003
Compare
db10bad to
c383001
Compare
6dfea26 to
5873f66
Compare
5873f66 to
2dd193f
Compare
68ad415 to
7b5caa0
Compare
c8255d5 to
b45198f
Compare
b45198f to
dafa7d7
Compare
|



This PR contains the automated changes for the
documentcollectorservice.Adyen/adyen-openapi@507d667
The commit history of this PR reflects the
adyen-openapicommits that have been applied.