document-drive 1.0.0-alpha.5 → 1.0.0-alpha.7
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 +1 -1
- package/src/server/index.ts +7 -2
- package/src/utils/index.ts +5 -0
package/package.json
CHANGED
package/src/server/index.ts
CHANGED
|
@@ -19,7 +19,12 @@ import {
|
|
|
19
19
|
import { createNanoEvents, Unsubscribe } from 'nanoevents';
|
|
20
20
|
import { MemoryStorage } from '../storage/memory';
|
|
21
21
|
import type { DocumentStorage, IDriveStorage } from '../storage/types';
|
|
22
|
-
import {
|
|
22
|
+
import {
|
|
23
|
+
generateUUID,
|
|
24
|
+
isBefore,
|
|
25
|
+
isDocumentDrive,
|
|
26
|
+
isNoopUpdate
|
|
27
|
+
} from '../utils';
|
|
23
28
|
import { requestPublicDrive } from '../utils/graphql';
|
|
24
29
|
import { OperationError } from './error';
|
|
25
30
|
import { ListenerManager } from './listener/manager';
|
|
@@ -306,7 +311,7 @@ export class DocumentDriveServer extends BaseDocumentDriveServer {
|
|
|
306
311
|
operation =>
|
|
307
312
|
Object.keys(filter).length === 0 ||
|
|
308
313
|
((filter.since === undefined ||
|
|
309
|
-
filter.since
|
|
314
|
+
isBefore(filter.since, operation.timestamp)) &&
|
|
310
315
|
(filter.fromRevision === undefined ||
|
|
311
316
|
operation.index > filter.fromRevision))
|
|
312
317
|
);
|
package/src/utils/index.ts
CHANGED