From 84cdd21e091b602be242956175c769127c443704 Mon Sep 17 00:00:00 2001 From: Shish Date: Sun, 1 Apr 2012 17:32:02 +0100 Subject: [PATCH] don't try to load notes if there are no notes --- ext/notes/script.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ext/notes/script.js b/ext/notes/script.js index 13aa4f54..c1a119f5 100644 --- a/ext/notes/script.js +++ b/ext/notes/script.js @@ -1,5 +1,7 @@ $(function() { - $('#main_image').imgNotes(); //If your notes data is is not named notes pass it + if(window.notes) { + $('#main_image').imgNotes(window.notes); + } $('#cancelnote').click(function(){ $('#main_image').imgAreaSelect({ hide: true });