Skip to content
Snippets Groups Projects
Commit 11a97de6 authored by Oleksandr Dubovyk's avatar Oleksandr Dubovyk
Browse files

Merge remote-tracking branch 'troll/MAGETWO-60128' into pull-primary

parents 858cc274 0195c22e
Branches
No related merge requests found
......@@ -11,11 +11,13 @@ define(
],
function($, ko, address) {
"use strict";
var isLoggedIn = ko.observable(window.isCustomerLoggedIn);
return {
getAddressItems: function() {
var items = [];
if (isLoggedIn) {
if (isLoggedIn()) {
var customerData = window.customerData;
if (Object.keys(customerData).length) {
$.each(customerData.addresses, function (key, item) {
......@@ -23,8 +25,9 @@ define(
});
}
}
return items;
}
}
}
);
\ No newline at end of file
);
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment