spd-lib 1.1.4 → 1.1.5

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.
Files changed (2) hide show
  1. package/index.js +7 -1
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -90,6 +90,8 @@ this.salt = salt;
90
90
  }
91
91
 
92
92
  async extractData() {
93
+ return new Promise(async(res,rej)=>{
94
+ try{
93
95
  await sodium.ready;
94
96
  let extractedFiles = {};
95
97
  this.data.forEach(async dat => {
@@ -98,7 +100,11 @@ this.salt = salt;
98
100
  const dt = decompressedData.toString('utf8');
99
101
  extractedFiles[dat.dataName] = await this.CSTI(dt, dat.dataType);
100
102
  });
101
- return extractedFiles;
103
+ res(extractedFiles);
104
+ }catch{
105
+ rej()
106
+ }
107
+ })
102
108
  }
103
109
 
104
110
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "spd-lib",
3
- "version": "1.1.4",
3
+ "version": "1.1.5",
4
4
  "description": "SPD or Secure Packaged Data is a compress PQC protected file format to store sensitive data localy",
5
5
  "main": "index.js",
6
6
  "scripts": {