From c3061231949fd2dfce79abac2956918fcbb09b77 Mon Sep 17 00:00:00 2001 From: github-actions-bot Date: Wed, 17 Apr 2024 19:02:55 +0000 Subject: [PATCH] fix: country not nullable --- Gemfile.lock | 2 +- lib/openapi_client/models/address_no_non_null_request.rb | 6 +++++- lib/openapi_client/version.rb | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index bf31e42..6f977e5 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,7 +1,7 @@ PATH remote: . specs: - affixapi (1.1.56) + affixapi (1.1.57) typhoeus (~> 1.0, >= 1.0.1) GEM diff --git a/lib/openapi_client/models/address_no_non_null_request.rb b/lib/openapi_client/models/address_no_non_null_request.rb index 0d6eb46..fd9fea2 100644 --- a/lib/openapi_client/models/address_no_non_null_request.rb +++ b/lib/openapi_client/models/address_no_non_null_request.rb @@ -82,7 +82,6 @@ def self.openapi_nullable :'street_address', :'locality', :'administrative_area', - :'country', :'post_code' ]) end @@ -127,12 +126,17 @@ def initialize(attributes = {}) # @return Array for valid properties with the reasons def list_invalid_properties invalid_properties = Array.new + if @country.nil? + invalid_properties.push('invalid value for "country", country cannot be nil.') + end + invalid_properties end # Check to see if the all the properties in the model are valid # @return true if the model is valid def valid? + return false if @country.nil? country_validator = EnumAttributeValidator.new('String', ["CA", "US", "MX", "AT", "AU", "BE", "CH", "CZ", "DE", "DK", "EE", "ES", "FI", "FR", "GB", "IE", "IM", "IS", "IT", "LI", "LT", "LT", "LV", "LU", "NL", "NO", "PH", "PL", "RO", "SE", "SG", "SK", "CN", "ID", "IN", "JP", "KR", "MO", "MY", "SG", "HK", "TW"]) return false unless country_validator.valid?(@country) true diff --git a/lib/openapi_client/version.rb b/lib/openapi_client/version.rb index d77e249..07bc5fb 100644 --- a/lib/openapi_client/version.rb +++ b/lib/openapi_client/version.rb @@ -11,5 +11,5 @@ =end module OpenapiClient - VERSION = '1.1.56' + VERSION = '1.1.57' end