@knowlearning/agents 0.3.13 → 0.3.14

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": "@knowlearning/agents",
3
- "version": "0.3.13",
3
+ "version": "0.3.14",
4
4
  "description": "API for embedding applications in KnowLearning systems.",
5
5
  "main": "node.js",
6
6
  "browser": "browser.js",
@@ -60,7 +60,7 @@ export default function MutableProxy(state, interact, ephemeralPaths={}, parentP
60
60
  // something smart around insertions/deletions
61
61
  // TODO: if is array and prop is last element, consider passing -1 as prop
62
62
  interact([{
63
- op: target[prop] ? 'replace' : 'add',
63
+ op: target[prop] === undefined ? 'add' : 'replace',
64
64
  value: JSON.parse(JSON.stringify(value)), // TODO: more efficient sanitization
65
65
  path
66
66
  }])