Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

web-storage-manager

Package Overview
Dependencies
Maintainers
1
Versions
48
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

web-storage-manager - npm Package Compare versions

Comparing version 1.0.9 to 1.0.10

44

lib/web-storage-manager.js

@@ -33,3 +33,3 @@ require("core-js/modules/es7.symbol.async-iterator");

} catch (error) {
return false;
throw error;
}

@@ -48,8 +48,6 @@ };

const encoded = this.encode(value);
console.log('encoded: ', encoded);
storage.setItem(key, encoded);
return true;
} catch (error) {
console.log('encoded error: ', error);
throw new Error('Unable to encode and save data');
throw error;
}

@@ -75,3 +73,3 @@ };

} catch (error) {
return false;
throw error;
}

@@ -98,4 +96,3 @@ };

} catch (error) {
console.log('encoded error: ', error);
return false;
throw error;
}

@@ -117,3 +114,3 @@ };

} catch (error) {
return false;
throw error;
}

@@ -135,4 +132,3 @@ };

} catch (error) {
console.log('encoded error: ', error);
return false;
throw error;
}

@@ -263,3 +259,3 @@ };

} catch (error) {
return false;
throw error;
}

@@ -358,4 +354,3 @@ };

} catch (error) {
console.log('encoded error: ', error);
return false;
throw error;
}

@@ -375,3 +370,3 @@ };

} catch (error) {
return null;
throw error;
}

@@ -392,4 +387,3 @@ };

} catch (error) {
console.log('encoded error: ', error);
return null;
throw error;
}

@@ -419,4 +413,3 @@ };

} catch (error) {
console.log('encoded error: ', error);
return null;
throw error;
}

@@ -446,4 +439,3 @@ };

} catch (error) {
console.log('encoded error: ', error);
return null;
throw error;
}

@@ -463,3 +455,3 @@ };

} catch (error) {
return false;
throw error;
}

@@ -482,3 +474,3 @@ };

} catch (error) {
return false;
throw error;
}

@@ -498,3 +490,3 @@ };

} catch (error) {
return false;
throw error;
}

@@ -511,3 +503,4 @@ };

const rawStr = JSON.stringify(obj);
const encObj = window.btoa(rawStr);
const encObj = window.btoa(rawStr); // console.log('encoded: ', encObj)
return encObj;

@@ -524,4 +517,5 @@ };

const decoded = window.atob(encObj);
const obj = JSON.parse(decoded);
const obj = JSON.parse(decoded); // console.log('decoded: ', encObj)
return obj;
};
{
"name": "web-storage-manager",
"version": "1.0.9",
"version": "1.0.10",
"description": "Web utility storage manager to handle save, update and data purge",

@@ -5,0 +5,0 @@ "main": "lib/web-storage-manager.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc