@steroidsjs/core 2.2.18 → 2.2.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -55,6 +55,7 @@ var ClientStorageComponent = /** @class */ (function () {
|
|
|
55
55
|
this.sessionStorageAvailable = false;
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
|
+
this.domain = (config === null || config === void 0 ? void 0 : config.domain) || null;
|
|
58
59
|
this._ssrCookie = config === null || config === void 0 ? void 0 : config.ssrCookie;
|
|
59
60
|
}
|
|
60
61
|
/**
|
|
@@ -122,7 +123,10 @@ var ClientStorageComponent = /** @class */ (function () {
|
|
|
122
123
|
}
|
|
123
124
|
};
|
|
124
125
|
ClientStorageComponent.prototype._getDomain = function () {
|
|
125
|
-
|
|
126
|
+
if (this.domain) {
|
|
127
|
+
return this.domain;
|
|
128
|
+
}
|
|
129
|
+
var host = (typeof window.location !== 'undefined' && window.location.hostname) || '';
|
|
126
130
|
return ((!/\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}/.test(host)
|
|
127
131
|
&& host
|
|
128
132
|
.split('.')
|