@toa.io/core 1.0.0-alpha.203 → 1.0.0-alpha.204

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@toa.io/core",
3
- "version": "1.0.0-alpha.203",
3
+ "version": "1.0.0-alpha.204",
4
4
  "description": "Toa Core",
5
5
  "author": "temich <tema.gurtovoy@gmail.com>",
6
6
  "homepage": "https://github.com/toa-io/toa#readme",
@@ -26,5 +26,5 @@
26
26
  "error-value": "0.3.0",
27
27
  "openspan": "1.0.0-alpha.173"
28
28
  },
29
- "gitHead": "d8997112ff3f275ec2079dc6e314e405e19f201a"
29
+ "gitHead": "1625cd465421f89eb1bc5feea249a7d943696df1"
30
30
  }
@@ -61,7 +61,7 @@ class Entity {
61
61
  return
62
62
 
63
63
  for (const guard of this.#guards) {
64
- const ok = guard.fit(value)
64
+ const ok = guard.fit(value, this.#state)
65
65
 
66
66
  if (ok === false)
67
67
  throw new EntityGuardException(guard.name, value)
package/src/guard.js CHANGED
@@ -9,8 +9,8 @@ class Guard {
9
9
  this.#bridge = bridge
10
10
  }
11
11
 
12
- fit (state) {
13
- return this.#bridge.fit(state)
12
+ fit (state, origin) {
13
+ return this.#bridge.fit(state, origin)
14
14
  }
15
15
  }
16
16