lib/economic/proxies/actions/find_by_number.rb in rconomic-0.5.2 vs lib/economic/proxies/actions/find_by_number.rb in rconomic-0.6.0
- old
+ new
@@ -1,19 +1,17 @@
module FindByNumber
# Returns handle with a given number.
def find_by_number(number)
- response = request('FindByNumber', {
- 'number' => number
- })
+ response = request("FindByNumber", "number" => number)
if response.empty?
nil
else
entity = build
entity.partial = true
entity.persisted = true
entity.handle = response
- entity.number = response[:number].to_i
+ entity.number = response[:number]
entity
end
end
end