@teamkeel/functions-runtime 0.240.0 → 0.240.2

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/package.json +1 -1
  2. package/src/ModelAPI.js +3 -5
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@teamkeel/functions-runtime",
3
- "version": "0.240.0",
3
+ "version": "0.240.2",
4
4
  "description": "Internal package used by @teamkeel/sdk",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
package/src/ModelAPI.js CHANGED
@@ -39,15 +39,13 @@ class ModelAPI {
39
39
  }
40
40
 
41
41
  async findMany(where) {
42
- let query = this._db
43
- .selectFrom(this._tableName)
44
- .selectAll();
42
+ let query = this._db.selectFrom(this._tableName).selectAll();
45
43
 
46
- // only apply constraints if there are keys in the where
44
+ // only apply constraints if there are keys in the where
47
45
  if (Object.keys(where).length > 0) {
48
46
  query = query.where((qb) => {
49
47
  return applyWhereConditions(qb, where);
50
- })
48
+ });
51
49
  }
52
50
 
53
51
  const rows = await query.execute();