sr-npm 1.7.472 → 1.7.474

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.
@@ -78,6 +78,7 @@ const COLLECTIONS_FIELDS = {
78
78
 
79
79
  const TOKEN_NAME = {
80
80
  COMPANY_ID: 'companyId',
81
+ COMPANY_ID_SM: 'companyID',
81
82
  SMART_TOKEN: 'x-smarttoken',
82
83
  }
83
84
 
package/backend/data.js CHANGED
@@ -374,7 +374,7 @@ async function fillSecretManagerMirror() {
374
374
  });
375
375
  console.log("x-smarttoken inserted into the SecretManagerMirror collection");
376
376
  } catch (error) {
377
- console.log("Error creating SecretManagerMirror collection:", error);
377
+ console.log("Error with inserting x-smarttoken into the SecretManagerMirror collection:", error);
378
378
  }
379
379
  }
380
380
 
@@ -1,16 +1,16 @@
1
1
  const { secrets } = require("@wix/secrets");
2
2
  const { auth } = require('@wix/essentials');
3
3
  const { items: wixData } = require('@wix/data');
4
- const { COLLECTIONS } = require('./collectionConsts');
4
+ const { COLLECTIONS,TOKEN_NAME } = require('./collectionConsts');
5
5
 
6
6
  const getSecretValue = auth.elevate(secrets.getSecretValue);
7
7
 
8
8
  function getSmartToken() {
9
- return retrieveSecretVal("x-smarttoken")
9
+ return retrieveSecretVal(TOKEN_NAME.SMART_TOKEN)
10
10
  }
11
11
 
12
12
  function getCompanyId() {
13
- return retrieveSecretVal("companyID")
13
+ return retrieveSecretVal(TOKEN_NAME.COMPANY_ID_SM)
14
14
  }
15
15
 
16
16
  async function retrieveSecretVal(tokenName)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sr-npm",
3
- "version": "1.7.472",
3
+ "version": "1.7.474",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {