lib/twilio-ruby/rest/pricing/v1/voice.rb in twilio-ruby-5.0.0.rc24 vs lib/twilio-ruby/rest/pricing/v1/voice.rb in twilio-ruby-5.0.0.rc25
- old
+ new
@@ -25,12 +25,15 @@
end
##
# Access the numbers
# @param [String] number The number
- # @return [NumberList] NumberList
+ # @return [NumberList] if a(n) NumberList object was created.
+ # @return [NumberContext] if a(n) NumberContext object was created.
def numbers(number=:unset)
+ raise ArgumentError, 'number cannot be nil' if number.nil?
+
if number != :unset
return NumberContext.new(
@version,
number,
)
@@ -42,11 +45,14 @@
end
##
# Access the countries
# @param [String] iso_country The iso_country
- # @return [CountryList] CountryList
+ # @return [CountryList] if a(n) CountryList object was created.
+ # @return [CountryContext] if a(n) CountryContext object was created.
def countries(iso_country=:unset)
+ raise ArgumentError, 'iso_country cannot be nil' if iso_country.nil?
+
if iso_country != :unset
return CountryContext.new(
@version,
iso_country,
)
\ No newline at end of file