diff --git a/CHANGELOG.md b/CHANGELOG.md index 9eccb0041d..089bb89815 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -20,6 +20,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Improved visibility of product SKU in wishlist - @PanMisza (#2606) - Instant focus to search input field after click on search icon in navbar - @ca1zr (#2608) - Added support for the newest node version - @gdomiciano (#2669) +- Used `$bus` plugin instead of EventBus import - @szafran89 (#2630) ## [1.9.0-rc.2] - UNRELEASED diff --git a/core/pages/Category.js b/core/pages/Category.js index cad3aa155b..ffa2884d47 100644 --- a/core/pages/Category.js +++ b/core/pages/Category.js @@ -249,7 +249,7 @@ export default { }) } this.$store.dispatch('category/products', this.getCurrentCategoryProductQuery) - EventBus.$emitFilter('category-after-load', { store: this.$store, route: route }) + this.$bus.$emitFilter('category-after-load', { store: this.$store, route: route }) } }).catch(err => { if (err.message.indexOf('query returned empty result') > 0) { diff --git a/core/pages/Product.js b/core/pages/Product.js index eb57279499..42811e993d 100644 --- a/core/pages/Product.js +++ b/core/pages/Product.js @@ -180,7 +180,7 @@ export default { this.$forceUpdate() }, onAfterFilterChanged (filterOption) { - EventBus.$emit('product-before-configure', { filterOption: filterOption, configuration: this.configuration }) + this.$bus.$emit('product-before-configure', { filterOption: filterOption, configuration: this.configuration }) const prevOption = this.configuration[filterOption.attribute_code] this.configuration[filterOption.attribute_code] = filterOption this.$forceUpdate() // this is to update the available options regarding current selection @@ -213,7 +213,7 @@ export default { onUserPricesRefreshed () { if (this.$route.params.parentSku) { this.$store.dispatch('product/reset') - EventBus.$emit('product-before-load', { store: this.$store, route: this.$route }) + this.$bus.$emit('product-before-load', { store: this.$store, route: this.$route }) this.$store.dispatch('product/single', { options: { sku: this.$route.params.parentSku, diff --git a/src/themes/default/layouts/Default.vue b/src/themes/default/layouts/Default.vue index 9ba6ff9f04..96467a615a 100644 --- a/src/themes/default/layouts/Default.vue +++ b/src/themes/default/layouts/Default.vue @@ -39,7 +39,6 @@