Permalink
Browse files

Ignore propreties that cannot be read

- This was required for IndexedDB as accessing properties throws
  exceptions
  • Loading branch information...
axemclion committed Mar 15, 2013
1 parent 3cc1fad commit f3b0da49f8de5a8326a2735abe7ca19c60232ab2
Showing with 12 additions and 2 deletions.
  1. +12 −2 js/ConsoleHelper.js
View
@@ -16,7 +16,12 @@ var ConsoleHelper = (function() {
result.push("<ol start = 0 style = 'display:none'>");
for ( var i = 0; i < data.length; i++) {
result.push("<li>");
result.push(getDomFromJSON(data[i]));
try{
result.push(getDomFromJSON(data[i]));
}
catch(e){
result.push("unknown");
}
result.push("</li>")
}
result.push("</ol></span>");
@@ -25,7 +30,12 @@ var ConsoleHelper = (function() {
result.push("<ul style = 'display:none'>");
for (x in data) {
result.push("<li>" + x);
result.push(":" + getDomFromJSON(data[x]));
try{
result.push(":" + getDomFromJSON(data[x]));
}
catch(e) {
result.push(x);
}
result.push("</li>")
}
result.push("</ul></span>");

0 comments on commit f3b0da4

Please sign in to comment.