Exception: Tienda::Errors::NotEnoughStock
- Inherits:
-
Tienda::Error
- Object
- StandardError
- Tienda::Error
- Tienda::Errors::NotEnoughStock
- Defined in:
- lib/tienda/errors/not_enough_stock.rb
Instance Method Summary collapse
Methods inherited from Tienda::Error
#initialize, #message, #options
Constructor Details
This class inherits a constructor from Tienda::Error
Instance Method Details
#available_stock ⇒ Object
4 5 6 |
# File 'lib/tienda/errors/not_enough_stock.rb', line 4 def available_stock @options[:ordered_item].stock end |
#requested_stock ⇒ Object
8 9 10 |
# File 'lib/tienda/errors/not_enough_stock.rb', line 8 def requested_stock @options[:requested_stock] end |