@friggframework/core 2.0.0-next.27 → 2.0.0-next.29

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.
@@ -8,6 +8,11 @@ const schema = new mongoose.Schema({
8
8
  // Add a static method to get active connections
9
9
  schema.statics.getActiveConnections = async function () {
10
10
  try {
11
+ // Return empty array if websockets are not configured
12
+ if (!process.env.WEBSOCKET_API_ENDPOINT) {
13
+ return [];
14
+ }
15
+
11
16
  const connections = await this.find({}, 'connectionId');
12
17
  return connections.map((conn) => ({
13
18
  connectionId: conn.connectionId,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@friggframework/core",
3
3
  "prettier": "@friggframework/prettier-config",
4
- "version": "2.0.0-next.27",
4
+ "version": "2.0.0-next.29",
5
5
  "dependencies": {
6
6
  "@hapi/boom": "^10.0.1",
7
7
  "aws-sdk": "^2.1200.0",
@@ -22,9 +22,9 @@
22
22
  "uuid": "^9.0.1"
23
23
  },
24
24
  "devDependencies": {
25
- "@friggframework/eslint-config": "2.0.0-next.27",
26
- "@friggframework/prettier-config": "2.0.0-next.27",
27
- "@friggframework/test": "2.0.0-next.27",
25
+ "@friggframework/eslint-config": "2.0.0-next.29",
26
+ "@friggframework/prettier-config": "2.0.0-next.29",
27
+ "@friggframework/test": "2.0.0-next.29",
28
28
  "@types/lodash": "4.17.15",
29
29
  "@typescript-eslint/eslint-plugin": "^8.0.0",
30
30
  "chai": "^4.3.6",
@@ -53,5 +53,5 @@
53
53
  },
54
54
  "homepage": "https://github.com/friggframework/frigg#readme",
55
55
  "description": "",
56
- "gitHead": "82dec739e8d482b55f995eecf088ef05f7931188"
56
+ "gitHead": "c6395f376547bd7e969797a2f92f380ba1ada0d5"
57
57
  }