mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-28 19:49:20 +03:00
Changed Knockout a bit
This commit is contained in:
parent
a352ebff25
commit
f105ed3f9d
15 changed files with 205 additions and 194 deletions
|
|
@ -72,13 +72,13 @@ ko.extenders['trackArrayChanges'] = (target, options) => {
|
|||
trackingChanges = true;
|
||||
|
||||
// Track how many times the array actually changed value
|
||||
spectateSubscription = target.subscribe(() => ++pendingChanges, null, "spectate");
|
||||
spectateSubscription = target['subscribe'](() => ++pendingChanges, null, "spectate");
|
||||
|
||||
// Each time the array changes value, capture a clone so that on the next
|
||||
// change it's possible to produce a diff
|
||||
previousContents = [].concat(target.peek() || []);
|
||||
cachedDiff = null;
|
||||
changeSubscription = target.subscribe(notifyChanges);
|
||||
changeSubscription = target['subscribe'](notifyChanges);
|
||||
}
|
||||
|
||||
function getChanges(previousContents, currentContents) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue