From 9041c08e85fb791170de5edb6fcd0dc28263cd4e Mon Sep 17 00:00:00 2001 From: Thomas Klein Date: Thu, 7 Jan 2021 12:23:55 +0100 Subject: [PATCH] use customerData promise --- view/frontend/web/js/view/country-store-data.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/view/frontend/web/js/view/country-store-data.js b/view/frontend/web/js/view/country-store-data.js index 91b0242..113670c 100644 --- a/view/frontend/web/js/view/country-store-data.js +++ b/view/frontend/web/js/view/country-store-data.js @@ -13,6 +13,12 @@ define([ return Component.extend({ initialize: function () { this._super(); + var _self = this; + + customerData.getInitCustomerData().done(function () { _self.initCountryStoreData(); }); + }, + + initCountryStoreData: function () { this.countryStoreData = customerData.get('country_store_data'); if (!this.isRefreshPending() && this.isInvalidated()) {