show specific error message when add-to-cart fails

This commit is contained in:
Andy Brett
2020-11-28 10:01:17 -08:00
parent 0824f12472
commit c70ea44091
4 changed files with 7 additions and 9 deletions

View File

@@ -50,7 +50,7 @@ Darkswarm.factory 'Cart', (CurrentOrder, Variants, $timeout, $http, $modal, $roo
@popQueue() if @update_enqueued
.error (response, status)=>
Messages.flash({error: t('js.cart.add_to_cart_failed')})
Messages.flash({error: response.error})
@update_running = false
compareAndNotifyStockLevels: (stockLevels) =>