@esvndev/es-react-config-setting 1.0.73 → 1.0.74

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.
package/dist/index.js CHANGED
@@ -19102,18 +19102,18 @@ const _FETCH_AND_UPDATE = () => {
19102
19102
  };
19103
19103
  //Add variable to localstorage
19104
19104
  const _LOAD_ = (data) => {
19105
- let _ = {};
19105
+ let _ = [];
19106
19106
  if (!data) {
19107
19107
  const _json = localStorage.getItem("app_config_setting");
19108
19108
  try {
19109
- _ = JSON.parse(_json ?? '{}');
19109
+ _ = JSON.parse(_json ?? '[]');
19110
19110
  }
19111
19111
  catch (ex) { }
19112
19112
  }
19113
19113
  Object.keys(GLOBAL_WINDOW_VARIABLE).forEach(key => delete GLOBAL_WINDOW_VARIABLE[key]);
19114
19114
  try {
19115
- for (var _p in _) {
19116
- GLOBAL_WINDOW_VARIABLE[_p] = _[_p];
19115
+ for (const _p of _) {
19116
+ GLOBAL_WINDOW_VARIABLE[_p.key] = _p;
19117
19117
  }
19118
19118
  }
19119
19119
  catch (ex) { }