Skip to content

Commit e02c113

Browse files
committed
Merge pull request #299 from magento-south/BUGS
[SOUTH] Bugs
2 parents bbc0e89 + 7eb55ab commit e02c113

File tree

5 files changed

+17
-20
lines changed

5 files changed

+17
-20
lines changed

app/code/Magento/Checkout/view/frontend/web/js/view/shipping-address/address-renderer/default.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ define([
1515
], function($, ko, Component, selectShippingAddressAction, quote, formPopUpState, checkoutData, customerData) {
1616
'use strict';
1717
var countryData = customerData.get('directory-data');
18+
1819
return Component.extend({
1920
defaults: {
2021
template: 'Magento_Checkout/shipping-address/address-renderer/default'

app/code/Magento/Checkout/view/frontend/web/js/view/shipping-information/address-renderer/default.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ define([
99
], function(Component, customerData) {
1010
'use strict';
1111
var countryData = customerData.get('directory-data');
12+
1213
return Component.extend({
1314
defaults: {
1415
template: 'Magento_Checkout/shipping-information/address-renderer/default'

app/code/Magento/Customer/view/frontend/web/js/customer-data.js

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -177,9 +177,13 @@ define([
177177
* Customer data initialization
178178
*/
179179
init: function() {
180-
var privateContent = $.cookieStorage.get('private_content_version');
181-
if (_.isEmpty(storage.keys()) && _.isObject(privateContent)) {
182-
this.reload([], false);
180+
var countryData,
181+
privateContent = $.cookieStorage.get('private_content_version');
182+
183+
if (_.isEmpty(storage.keys())) {
184+
if (!_.isEmpty(privateContent)) {
185+
this.reload([], false);
186+
}
183187
} else if (this.needReload()) {
184188
_.each(dataProvider.getFromStorage(storage.keys()), function (sectionData, sectionName) {
185189
buffer.notify(sectionName, sectionData);
@@ -194,6 +198,13 @@ define([
194198
this.reload(storageInvalidation.keys(), false);
195199
}
196200
}
201+
202+
if (!_.isEmpty(privateContent)) {
203+
countryData = this.get('directory-data');
204+
if (_.isEmpty(countryData())) {
205+
countryData(customerData.reload(['directory-data'], false));
206+
}
207+
}
197208
},
198209

199210
/**

app/code/Magento/Theme/Console/Command/ThemeUninstallCommand.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,7 @@ private function validate($themePaths)
248248
$text = 'Theme path should be specified as full path which is area/vendor/name.';
249249
$messages[] = '<error>Incorrect theme(s) format: ' . implode(', ', $incorrectThemes)
250250
. '. ' . $text . '</error>';
251+
return $messages;
251252
}
252253

253254
$unknownPackages = $this->getUnknownPackages($themePaths);

app/code/Magento/Theme/Test/Unit/Console/Command/ThemeUninstallCommandTest.php

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -318,23 +318,6 @@ public function testExecuteCleanStaticFiles()
318318
*/
319319
public function testExecuteWrongThemeFormat($themePath)
320320
{
321-
$this->themePackageInfo->expects($this->once())
322-
->method('getPackageName')
323-
->willReturn('dummy');
324-
325-
$themeMock = $this->getMockBuilder('Magento\Framework\View\Design\ThemeInterface')
326-
->getMockForAbstractClass();
327-
328-
$this->collection->expects($this->once())
329-
->method('getThemeByFullPath')
330-
->with($themePath)
331-
->willReturn($themeMock);
332-
333-
$this->collection->expects($this->once())
334-
->method('hasTheme')
335-
->with($themeMock)
336-
->willReturn(false);
337-
338321
$this->tester->execute(['theme' => [$themePath]]);
339322
$this->assertContains(
340323
'Theme path should be specified as full path which is area/vendor/name.',

0 commit comments

Comments
 (0)