Mercurial > urweb
diff lib/js/urweb.js @ 1625:bd34a4af516a
Change client-side debug to use console.debug
author | Adam Chlipala <adam@chlipala.net> |
---|---|
date | Sat, 03 Dec 2011 16:25:09 -0500 |
parents | f96e708b4b93 |
children | 438561303d02 |
line wrap: on
line diff
--- a/lib/js/urweb.js Sat Dec 03 16:05:06 2011 -0500 +++ b/lib/js/urweb.js Sat Dec 03 16:25:09 2011 -0500 @@ -338,6 +338,16 @@ // Error handling +function uw_debug(msg) { + try { + console.debug(msg); + } catch (e) { + alert("DEBUG: " + msg); + } + + return 0; +} + function whine(msg) { alert(msg); throw msg;