sishen / uber-ruby

A Ruby Interface to the Uber API
MIT License
47 stars 42 forks source link

Handle errors #21

Open AnkurGel opened 8 years ago

AnkurGel commented 8 years ago

Do not merge this yet @sishen : I'm using raise_error middleware of Faraday and passing the message to Uber::Error.from_error which raises exception based on status code. Though, this is not a good solution for Request errors, since it was being handled by RequestError earlier. Should I re-use this for Request and continue to use Uber::Error for others? Suggestions?