From 968266079c09e55c2ba2486448c06788eb39bdd9 Mon Sep 17 00:00:00 2001 From: Dan Helfman Date: Fri, 14 Nov 2008 17:01:55 -0800 Subject: [PATCH] Fixed a visual bug in which undoing the deletion of a note didn't always make the note reappear, even though the undeletion always worked. --- NEWS | 2 ++ static/js/Wiki.js | 14 ++++++-------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/NEWS b/NEWS index b2cb115..2c62f5a 100644 --- a/NEWS +++ b/NEWS @@ -5,6 +5,8 @@ having to click "options" -> "show on startup". * Fixed a bug in which search result note summaries were not showing the portion of the note that matched the search term. (Luminotes Server) + * Fixed a visual bug in which undoing the deletion of a note didn't always + make the note reappear, even though the undeletion always worked. 1.5.6: November 12, 2008 * Greatly improved the speed of wiki searching for Luminotes Server and diff --git a/static/js/Wiki.js b/static/js/Wiki.js index cd0a97b..98cc857 100644 --- a/static/js/Wiki.js +++ b/static/js/Wiki.js @@ -1546,12 +1546,11 @@ Wiki.prototype.undelete_editor_via_undo = function( event, editor, position_afte self.display_storage_usage( result.storage_bytes ); self.clear_messages(); self.clear_pulldowns(); + self.startup_notes[ editor.id ] = true; + self.increment_total_notes_count(); + self.load_editor( "Note not found.", editor.id, null, null, null, position_after ); } ); } - - this.startup_notes[ editor.id ] = true; - this.increment_total_notes_count(); - this.load_editor( "Note not found.", editor.id, null, null, null, position_after ); } event.stop(); @@ -1567,13 +1566,12 @@ Wiki.prototype.undelete_editor_via_undelete = function( event, note_id, position self.display_storage_usage( result.storage_bytes ); self.clear_messages(); self.clear_pulldowns(); + self.startup_notes[ note_id ] = true; + self.increment_total_notes_count(); + self.load_editor( "Note not found.", note_id, null, null, null, position_after ); } ); } - this.startup_notes[ note_id ] = true; - this.increment_total_notes_count(); - this.load_editor( "Note not found.", note_id, null, null, null, position_after ); - event.stop(); }