Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed / Improved

- use yarn in cli installer - @gibkigonzo (#4292)
- disable out of stock notification when config.stock.allowOutOfStockInCart is true - @gibigonzo (#4340)


### Fixed
Expand Down
3 changes: 2 additions & 1 deletion core/modules/cart/store/actions/itemActions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
notifications
} from '@vue-storefront/core/modules/cart/helpers'
import { cartHooksExecutors } from './../../hooks'
import config from 'config'

const itemActions = {
async configureItem (context, { product, configuration }) {
Expand Down Expand Up @@ -62,7 +63,7 @@ const itemActions = {
if (errors.length === 0) {
const { status, onlineCheckTaskId } = await dispatch('checkProductStatus', { product })

if (status === 'volatile') {
if (status === 'volatile' && !config.stock.allowOutOfStockInCart) {
diffLog.pushNotification(notifications.unsafeQuantity())
}
if (status === 'out_of_stock') {
Expand Down