Skip to content

Commit d06887a

Browse files
committed
Update parameters for orders
1 parent 99d7634 commit d06887a

File tree

5 files changed

+20
-19
lines changed

5 files changed

+20
-19
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,4 +42,5 @@ build/
4242
.openapi-generator-ignore
4343
/.openapi-generator/
4444

45-
.byebug_history
45+
.byebug_history
46+
.DS_Store

lib/patch_ruby/models/create_mass_estimate_request.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,8 @@ def list_invalid_properties
9898
invalid_properties.push('invalid value for "mass_g", must be smaller than or equal to 2000000000.')
9999
end
100100

101-
if @mass_g < 1
102-
invalid_properties.push('invalid value for "mass_g", must be greater than or equal to 1.')
101+
if @mass_g < 0
102+
invalid_properties.push('invalid value for "mass_g", must be greater than or equal to 0.')
103103
end
104104

105105
invalid_properties
@@ -110,7 +110,7 @@ def list_invalid_properties
110110
def valid?
111111
return false if @mass_g.nil?
112112
return false if @mass_g > 2000000000
113-
return false if @mass_g < 1
113+
return false if @mass_g < 0
114114
true
115115
end
116116

@@ -125,8 +125,8 @@ def mass_g=(mass_g)
125125
fail ArgumentError, 'invalid value for "mass_g", must be smaller than or equal to 2000000000.'
126126
end
127127

128-
if mass_g < 1
129-
fail ArgumentError, 'invalid value for "mass_g", must be greater than or equal to 1.'
128+
if mass_g < 0
129+
fail ArgumentError, 'invalid value for "mass_g", must be greater than or equal to 0.'
130130
end
131131

132132
@mass_g = mass_g

lib/patch_ruby/models/create_order_request.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,8 @@ def list_invalid_properties
100100
invalid_properties.push('invalid value for "mass_g", must be smaller than or equal to 2000000000.')
101101
end
102102

103-
if !@mass_g.nil? && @mass_g < 1
104-
invalid_properties.push('invalid value for "mass_g", must be greater than or equal to 1.')
103+
if !@mass_g.nil? && @mass_g < 0
104+
invalid_properties.push('invalid value for "mass_g", must be greater than or equal to 0.')
105105
end
106106

107107
if !@total_price_cents_usd.nil? && @total_price_cents_usd < 1
@@ -115,7 +115,7 @@ def list_invalid_properties
115115
# @return true if the model is valid
116116
def valid?
117117
return false if !@mass_g.nil? && @mass_g > 2000000000
118-
return false if !@mass_g.nil? && @mass_g < 1
118+
return false if !@mass_g.nil? && @mass_g < 0
119119
return false if !@total_price_cents_usd.nil? && @total_price_cents_usd < 1
120120
true
121121
end
@@ -127,8 +127,8 @@ def mass_g=(mass_g)
127127
fail ArgumentError, 'invalid value for "mass_g", must be smaller than or equal to 2000000000.'
128128
end
129129

130-
if !mass_g.nil? && mass_g < 1
131-
fail ArgumentError, 'invalid value for "mass_g", must be greater than or equal to 1.'
130+
if !mass_g.nil? && mass_g < 0
131+
fail ArgumentError, 'invalid value for "mass_g", must be greater than or equal to 0.'
132132
end
133133

134134
@mass_g = mass_g

lib/patch_ruby/models/order.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -185,8 +185,8 @@ def list_invalid_properties
185185
invalid_properties.push('invalid value for "mass_g", must be smaller than or equal to 2000000000.')
186186
end
187187

188-
if @mass_g < 1
189-
invalid_properties.push('invalid value for "mass_g", must be greater than or equal to 1.')
188+
if @mass_g < 0
189+
invalid_properties.push('invalid value for "mass_g", must be greater than or equal to 0.')
190190
end
191191

192192
if @production.nil?
@@ -218,7 +218,7 @@ def valid?
218218
return false if @id.nil?
219219
return false if @mass_g.nil?
220220
return false if @mass_g > 2000000000
221-
return false if @mass_g < 1
221+
return false if @mass_g < 0
222222
return false if @production.nil?
223223
return false if @state.nil?
224224
state_validator = EnumAttributeValidator.new('String', ["draft", "placed", "complete", "cancelled"])
@@ -242,8 +242,8 @@ def mass_g=(mass_g)
242242
fail ArgumentError, 'invalid value for "mass_g", must be smaller than or equal to 2000000000.'
243243
end
244244

245-
if mass_g < 1
246-
fail ArgumentError, 'invalid value for "mass_g", must be greater than or equal to 1.'
245+
if mass_g < 0
246+
fail ArgumentError, 'invalid value for "mass_g", must be greater than or equal to 0.'
247247
end
248248

249249
@mass_g = mass_g

lib/patch_ruby/models/project.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class Project
2626
# The description of the project.
2727
attr_accessor :description
2828

29-
# The type of carbon removal project, currently available project types are Biomass, Dac, Forestry, Mineralization, Ocean, Soil.
29+
# The type of carbon removal project, currently available project types are Biomass, Dac, Forestry, Mineralization, Ocean, Renewables, Soil.
3030
attr_accessor :type
3131

3232
# The country of origin of the project.
@@ -246,7 +246,7 @@ def valid?
246246
return false if @production.nil?
247247
return false if @name.nil?
248248
return false if @description.nil?
249-
type_validator = EnumAttributeValidator.new('String', ["biomass", "dac", "forestry", "mineralization", "ocean", "soil"])
249+
type_validator = EnumAttributeValidator.new('String', ["biomass", "dac", "forestry", "mineralization", "ocean", "renewables", "soil"])
250250
return false unless type_validator.valid?(@type)
251251
return false if @country.nil?
252252
return false if @developer.nil?
@@ -258,7 +258,7 @@ def valid?
258258
# Custom attribute writer method checking allowed values (enum).
259259
# @param [Object] type Object to be assigned
260260
def type=(type)
261-
validator = EnumAttributeValidator.new('String', ["biomass", "dac", "forestry", "mineralization", "ocean", "soil"])
261+
validator = EnumAttributeValidator.new('String', ["biomass", "dac", "forestry", "mineralization", "ocean", "renewables", "soil"])
262262
unless validator.valid?(type)
263263
fail ArgumentError, "invalid value for \"type\", must be one of #{validator.allowable_values}."
264264
end

0 commit comments

Comments
 (0)