From 65736aa278e66aec2fcfefe7aac9375032cb2ef9 Mon Sep 17 00:00:00 2001 From: "Jeremy Wall (zaphar)" Date: Sat, 20 Apr 2013 14:08:18 -0500 Subject: [PATCH] Api change for the db code SetDebug -> ToggleDebug. --- js/common.js | 2 +- js/db.js | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/js/common.js b/js/common.js index ecff5c07..21ab20ee 100644 --- a/js/common.js +++ b/js/common.js @@ -305,7 +305,7 @@ define(['jquery', 'reference', 'tagging', 'jquery.ui'], t.find(".removeresult").click(function(e) { Util.RemoveResult(e); }); - // TODO(jwall): support longtouch events on mobile. + // TODO(jwall): support longtouch events on mobile? t.find(".resultbody h2").tooltip({ items: ".resultbody h2", content: function(tt) { diff --git a/js/db.js b/js/db.js index 209af1fd..17b6f9b8 100644 --- a/js/db.js +++ b/js/db.js @@ -7,7 +7,7 @@ define( version: 1, dbName: "dynamic_bible_db", stores: ['tags'], - debug: true, + debug: false, // Internal method not for external use. handleError: function(e) { this.debug && console.log("Error: ", e); @@ -24,9 +24,9 @@ define( } } }, - // Turn on debug logging. - SetDebug: function() { - this.debug = self; + // Turn on/off debug logging. + ToggleDebug: function() { + this.debug = !this.debug; }, // Session does operations on an open database. // ops is expected to be a function taking an IDBDatabase object