Permalink
Browse files

Return if no cb is supplied.

Signed-off-by: Nick Campbell <nicholas.j.campbell@gmail.com>
  • Loading branch information...
1 parent f43c2d8 commit a3c2aea62403c46a7ac33a94256437bb121cab9e @ncb000gt committed Feb 1, 2011
Showing with 2 additions and 0 deletions.
  1. +2 −0 lib/bbcode.js
View
@@ -255,5 +255,7 @@ BBCode.prototype.parse = function(post, cb) {
var ret = endtags ? result + endtags : result;
if (cb) {
cb(ret);
+ } else {
+ return ret;
}
}

0 comments on commit a3c2aea

Please sign in to comment.