@cocreate/unique 1.4.0 → 1.4.1

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/CHANGELOG.md CHANGED
@@ -1,3 +1,11 @@
1
+ ## [1.4.1](https://github.com/CoCreate-app/CoCreate-unique/compare/v1.4.0...v1.4.1) (2022-05-17)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * get orgId from socketInfo ([2edff44](https://github.com/CoCreate-app/CoCreate-unique/commit/2edff44369733c525c6cc1e4fd3881f8d3dc889b))
7
+ * update document_id on link index.css ([661d333](https://github.com/CoCreate-app/CoCreate-unique/commit/661d333a5af6dd272ff2f0d8d84f073ec9366dec))
8
+
1
9
  # [1.4.0](https://github.com/CoCreate-app/CoCreate-unique/compare/v1.3.2...v1.4.0) (2022-05-14)
2
10
 
3
11
 
package/docs/index.html CHANGED
@@ -13,7 +13,7 @@
13
13
 
14
14
  <!-- CoCreate CSS -->
15
15
  <link rel="stylesheet" href="https://cdn.cocreate.app/latest/CoCreate.min.css" type="text/css"/>
16
- <link rel="stylesheet" href="/docs/index.css" collection="files" document_id="60888216117c640e7596303f" name="src" type="text/css" save="true"/>
16
+ <link rel="stylesheet" href="/docs/index.css" collection="files" document_id="62827d7e8082ce05b081430b" name="src" type="text/css" save="true"/>
17
17
  </head>
18
18
 
19
19
  <body>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cocreate/unique",
3
- "version": "1.4.0",
3
+ "version": "1.4.1",
4
4
  "description": "A simple unique component in vanilla javascript. Easily configured using HTML5 attributes and/or JavaScript API.",
5
5
  "keywords": [
6
6
  "unique",
package/src/server.js CHANGED
@@ -13,7 +13,7 @@ class CoCreateUnique {
13
13
  }
14
14
 
15
15
 
16
- async checkUnique(socket, req_data) {
16
+ async checkUnique(socket, req_data, socketInfo) {
17
17
  const self = this
18
18
  const db = this.dbClient.db(req_data['organization_id']);
19
19
  const collection = db.collection(req_data["collection"]);
@@ -32,7 +32,7 @@ class CoCreateUnique {
32
32
  if (result.length) {
33
33
  response.unique = false;
34
34
  }
35
- self.wsManager.send(socket, 'checkedUnique', response, req_data['organization_id']);
35
+ self.wsManager.send(socket, 'checkedUnique', response, socketInfo);
36
36
  }
37
37
  });
38
38
  } catch (error) {