Permalink
Browse files

Merge pull request #12 from calebegg/master

Added support for report() accepting a node instead of just text or an array.
  • Loading branch information...
chrisdone committed Nov 11, 2011
2 parents 041787a + 20b97c3 commit 055c2c212944349ddbb045e8536ebfb2192acb80
Showing with 3 additions and 1 deletion.
  1. +3 −1 jquery.console.js
View
@@ -472,11 +472,13 @@
updatePromptDisplay();
if (typeof msg == 'string') {
message(msg,className);
- } else {
+ } else if ($.isArray(msg)) {
for (var x in msg) {
var ret = msg[x];
message(ret.msg,ret.className);
}
+ } else { // Assume it's a DOM node or jQuery object.
+ inner.append(msg);
}
newPromptBox();
};

0 comments on commit 055c2c2

Please sign in to comment.