From fbb71c76673eaf3e44d2931386729ef3ba10a446 Mon Sep 17 00:00:00 2001 From: "mvl%exedo.nl" Date: Tue, 5 Jul 2005 21:47:16 +0000 Subject: [PATCH] Fixes to memory provider's modifyItem. bug 299760, r=shaver --- calendar/providers/memory/calMemoryCalendar.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/calendar/providers/memory/calMemoryCalendar.js b/calendar/providers/memory/calMemoryCalendar.js index 50161a6feb6..27b0bf473d9 100644 --- a/calendar/providers/memory/calMemoryCalendar.js +++ b/calendar/providers/memory/calMemoryCalendar.js @@ -202,8 +202,7 @@ calMemoryCalendar.prototype = { return; } - if (aOldItem.id != this.mItems[aOldItem.id] || - aOldItem.generation != aOldItem.generation) { + if (aOldItem != this.mItems[aOldItem.id]) { if (aListener) aListener.onOperationComplete (this.calendarToReturn, Components.results.NS_ERROR_FAILURE, @@ -226,7 +225,7 @@ calMemoryCalendar.prototype = { var modifiedItem = aNewItem.clone(); modifiedItem.generation += 1; modifiedItem.makeImmutable(); - this.mItems[newItem.id] = modifiedItem; + this.mItems[aNewItem.id] = modifiedItem; if (aListener) aListener.onOperationComplete (this.calendarToReturn,