Merge pull request #7452 from NativeScript/mdonev/observable-array-splice-fix

fix(observable-array): splice to notify correct amount of added items
This commit is contained in:
Manol Donev
2019-07-04 15:45:07 +03:00
committed by GitHub
2 changed files with 3 additions and 3 deletions

View File

@@ -207,7 +207,7 @@ export class ObservableArray<T> extends observable.Observable implements observa
action: ChangeType.Splice,
index: start,
removed: result,
addedCount: this._array.length > length ? this._array.length - length : 0
addedCount: this._array.length + result.length - length
});
if (this._array.length !== length) {
this._notifyLengthChange();