@travetto/model-mongo 3.1.5 → 3.1.6
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/package.json +3 -3
- package/src/service.ts +1 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@travetto/model-mongo",
|
|
3
|
-
"version": "3.1.
|
|
3
|
+
"version": "3.1.6",
|
|
4
4
|
"description": "Mongo backing for the travetto model module.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"mongo",
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"@travetto/config": "^3.1.2",
|
|
29
|
-
"@travetto/model": "^3.1.
|
|
30
|
-
"@travetto/model-query": "^3.1.
|
|
29
|
+
"@travetto/model": "^3.1.8",
|
|
30
|
+
"@travetto/model-query": "^3.1.6",
|
|
31
31
|
"mongodb": "^5.0.1"
|
|
32
32
|
},
|
|
33
33
|
"peerDependencies": {
|
package/src/service.ts
CHANGED
|
@@ -311,9 +311,7 @@ export class MongoModelService implements
|
|
|
311
311
|
async getStreamPartial(location: string, start: number, end?: number): Promise<PartialStream> {
|
|
312
312
|
const meta = await this.describeStream(location);
|
|
313
313
|
|
|
314
|
-
end
|
|
315
|
-
|
|
316
|
-
ModelStreamUtil.checkRange(start, end, meta.size);
|
|
314
|
+
[start, end] = ModelStreamUtil.enforceRange(start, end, meta.size);
|
|
317
315
|
|
|
318
316
|
const res = await this.#bucket.openDownloadStreamByName(location, { start, end: end + 1 });
|
|
319
317
|
if (!res) {
|