Update vehicle.rb

This commit is contained in:
2016-05-31 07:53:29 -04:00
parent 5c0c0cc657
commit e7ae654066

View File

@@ -28,7 +28,7 @@ class Vehicle < ActiveRecord::Base
# returns a human readable string
def to_s
return "#{customer.name} - #{year} #{make} #{model}"
return "#{customer.name if customer} - #{year} #{make} #{model}"
end
# returns the raw JSON details from EMUNDS