@mtgame/core 2.0.9 → 2.0.10

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.
@@ -1713,8 +1713,11 @@ function updateItemInArray(data, item, force = false, checkFunction) {
1713
1713
  !force && item.updatedAt && oldItem.updatedAt && oldItem.updatedAt > item.updatedAt) {
1714
1714
  return data;
1715
1715
  }
1716
- data[index] = item;
1717
- return data;
1716
+ return [
1717
+ ...data.slice(0, index),
1718
+ item,
1719
+ ...data.slice(index + 1),
1720
+ ];
1718
1721
  }
1719
1722
  function updateItemsInArray(data, items, force = false, checkFunction) {
1720
1723
  items.forEach(item => {