@twin.org/entity-storage-connector-file 0.0.1-next.11 → 0.0.1-next.13

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.
@@ -179,7 +179,10 @@ class FileEntityStorageConnector {
179
179
  if (entity.EntityConditions.check(allEntities[i], conditions) && entities.length < finalPageSize) {
180
180
  entities.push(core.ObjectHelper.pick(allEntities[i], properties));
181
181
  if (entities.length >= finalPageSize) {
182
- nextCursor = (i + 1).toString();
182
+ if (i < allEntities.length - 1) {
183
+ nextCursor = (i + 1).toString();
184
+ }
185
+ break;
183
186
  }
184
187
  }
185
188
  }
@@ -177,7 +177,10 @@ class FileEntityStorageConnector {
177
177
  if (EntityConditions.check(allEntities[i], conditions) && entities.length < finalPageSize) {
178
178
  entities.push(ObjectHelper.pick(allEntities[i], properties));
179
179
  if (entities.length >= finalPageSize) {
180
- nextCursor = (i + 1).toString();
180
+ if (i < allEntities.length - 1) {
181
+ nextCursor = (i + 1).toString();
182
+ }
183
+ break;
181
184
  }
182
185
  }
183
186
  }
package/docs/changelog.md CHANGED
@@ -1,5 +1,5 @@
1
1
  # @twin.org/entity-storage-connector-file - Changelog
2
2
 
3
- ## v0.0.1-next.11
3
+ ## v0.0.1-next.13
4
4
 
5
5
  - Initial Release
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@twin.org/entity-storage-connector-file",
3
- "version": "0.0.1-next.11",
3
+ "version": "0.0.1-next.13",
4
4
  "description": "Entity Storage connector implementation using file storage",
5
5
  "repository": {
6
6
  "type": "git",
@@ -16,7 +16,7 @@
16
16
  "dependencies": {
17
17
  "@twin.org/core": "next",
18
18
  "@twin.org/entity": "next",
19
- "@twin.org/entity-storage-models": "0.0.1-next.11",
19
+ "@twin.org/entity-storage-models": "0.0.1-next.13",
20
20
  "@twin.org/logging-models": "next",
21
21
  "@twin.org/nameof": "next"
22
22
  },