From 6786f9801a8ef7897e9415569b0dd5c69afd7799 Mon Sep 17 00:00:00 2001 From: Dan Helfman Date: Thu, 11 Oct 2007 11:29:42 +0000 Subject: [PATCH] No longer asking the server for revisions for a note that hasn't been saved yet. --- static/js/Wiki.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/static/js/Wiki.js b/static/js/Wiki.js index 22dcf32..3b14692 100644 --- a/static/js/Wiki.js +++ b/static/js/Wiki.js @@ -1140,8 +1140,9 @@ Wiki.prototype.toggle_editor_changes = function ( event, editor ) { event.stop(); - // if there's already a cached revision list, display the changes pulldown with it - if ( editor.revisions_list && editor.revisions_list.length > 0 ) { + // if there's already a cached revision list, or the editor doesn't have a revision yet, then + // display the changes pulldown and bail + if ( ( editor.revisions_list && editor.revisions_list.length > 0 ) || !editor.revision ) { new Changes_pulldown( this, this.notebook_id, this.invoker, editor ); return; }