rheactor-event-store
Advanced tools
Comparing version 9.2.1 to 9.2.2
@@ -185,3 +185,3 @@ 'use strict'; | ||
value: function is(x) { | ||
return x instanceof AggregateRoot || x && x.constructor && x.constructor.name === AggregateRoot.name && '$aggregateMeta' in x && 'id' in x.$aggregateMeta && 'version' in x.$aggregateMeta && 'deleted' in x.$aggregateMeta && 'createdAt' in x.$aggregateMeta && 'updatedAt' in x.$aggregateMeta && 'deletedAt' in x.$aggregateMeta; | ||
return x instanceof AggregateRoot || x && x.constructor && x.constructor.name === AggregateRoot.name && 'persisted' in x && 'updated' in x && 'deleted' in x && 'aggregateVersion' in x && 'aggregateId' in x && 'isDeleted' in x && 'createdAt' in x && 'modifiedAt' in x && 'updatedAt' in x && 'deletedAt' in x; | ||
} | ||
@@ -188,0 +188,0 @@ }]); |
{ | ||
"name": "rheactor-event-store", | ||
"description": "Implementation of an event store based on redis", | ||
"version": "9.2.1", | ||
"version": "9.2.2", | ||
"main": "dist/index.js", | ||
@@ -6,0 +6,0 @@ "scripts": { |
@@ -135,9 +135,12 @@ import {AggregateIdType} from './types' | ||
x.constructor.name === AggregateRoot.name && | ||
'$aggregateMeta' in x && | ||
'id' in x.$aggregateMeta && | ||
'version' in x.$aggregateMeta && | ||
'deleted' in x.$aggregateMeta && | ||
'createdAt' in x.$aggregateMeta && | ||
'updatedAt' in x.$aggregateMeta && | ||
'deletedAt' in x.$aggregateMeta | ||
'persisted' in x && | ||
'updated' in x && | ||
'deleted' in x && | ||
'aggregateVersion' in x && | ||
'aggregateId' in x && | ||
'isDeleted' in x && | ||
'createdAt' in x && | ||
'modifiedAt' in x && | ||
'updatedAt' in x && | ||
'deletedAt' in x | ||
) | ||
@@ -144,0 +147,0 @@ } |
@@ -95,10 +95,12 @@ /* global describe, it */ | ||
constructor: {name: AggregateRoot.name}, | ||
$aggregateMeta: { | ||
id: null, | ||
version: null, | ||
deleted: false, | ||
createdAt: null, | ||
updatedAt: null, | ||
deletedAt: null | ||
} | ||
persisted: () => {}, | ||
updated: () => {}, | ||
deleted: () => {}, | ||
aggregateVersion: () => {}, | ||
aggregateId: () => {}, | ||
isDeleted: () => {}, | ||
createdAt: () => {}, | ||
modifiedAt: () => {}, | ||
updatedAt: () => {}, | ||
deletedAt: () => {} | ||
} | ||
@@ -105,0 +107,0 @@ expect(AggregateRoot.is(root)).to.equal(true) |
69574
1894