Comparing version 2.2.0 to 2.3.0
@@ -66,4 +66,7 @@ (function() { | ||
modifier(draft); | ||
if (draft.$dirty === original.dirty) { | ||
draft.$dirty = true; | ||
/* TAINT simplify logic by rewriting as single term without double negatives */ | ||
if (this.settings.dirty) { | ||
if (draft.$dirty === original.dirty) { | ||
draft.$dirty = true; | ||
} | ||
} | ||
@@ -77,4 +80,7 @@ } | ||
modifier(draft); | ||
if (draft.$dirty === original.dirty) { | ||
draft.$dirty = true; | ||
/* TAINT simplify logic by rewriting as single term without double negatives */ | ||
if (this.settings.dirty) { | ||
if (draft.$dirty === original.dirty) { | ||
draft.$dirty = true; | ||
} | ||
} | ||
@@ -81,0 +87,0 @@ } |
@@ -111,3 +111,4 @@ (function() { | ||
merge_values: true, | ||
freeze: true | ||
freeze: true, | ||
dirty: true | ||
} | ||
@@ -114,0 +115,0 @@ }; |
@@ -48,3 +48,6 @@ (function() { | ||
this._mark_as_primary = function(x) { | ||
return DATOM.new_datom('~XEMITTER-preferred', x); | ||
return DATOM.wrap_datom('~XEMITTER-preferred', { | ||
$key: '~wrapper', | ||
$value: x | ||
}); | ||
}; | ||
@@ -61,3 +64,3 @@ this._filter_primary = function(x) { | ||
} | ||
return (ref = primary_responses[0]) != null ? ref.$value : void 0; | ||
return (ref = primary_responses[0]) != null ? ref.$value.$value : void 0; | ||
}; | ||
@@ -64,0 +67,0 @@ //--------------------------------------------------------------------------------------------------------- |
{ | ||
"name": "datom", | ||
"version": "2.2.0", | ||
"version": "2.3.0", | ||
"description": "standardized immutable objects in the spirit of datomic, especially suited for use in data pipelines", | ||
@@ -5,0 +5,0 @@ "main": "lib/main.js", |
@@ -82,2 +82,6 @@ | ||
* **`dirty`** (boolean, default: `true`)—Whether to automatically set `{ $dirty: true, }` when the copy | ||
of a datom has been treated with `lets()` and a modifyer function. | ||
# Methods | ||
@@ -84,0 +88,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
95746
1356
326