Update vehicle.rb

This commit is contained in:
2016-04-29 07:26:30 -04:00
parent 43876fb61d
commit a8ce05d8a6

View File

@@ -54,7 +54,11 @@ class Vehicle < ActiveRecord::Base
def get_details
# TODO handle ERRORS
if self.vin?
@details = JSON.parse get_decoder.full(self.vin)
begin
@details = JSON.parse get_decoder.full(self.vin)
rescue
return nil
end
end
end