Skip to content

Commit fbaa581

Browse files
authored
Allow empty string arguments in options table (#35)
1 parent 27d1cc7 commit fbaa581

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/Renderer.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -421,13 +421,13 @@ function RendererOptions(options) {
421421
options = options || {};
422422
this.indentSize =
423423
options.indentSize ? this._parseEmVal(options.indentSize) : 1.2;
424-
this.commentDelimiter = options.commentDelimiter || ' // ';
425-
this.lineNumberPunc = options.lineNumberPunc || ':';
424+
this.commentDelimiter = options.commentDelimiter !== undefined ? options.commentDelimiter : ' // ';
425+
this.lineNumberPunc = options.lineNumberPunc !== undefined ? options.lineNumberPunc : ':';
426426
this.lineNumber = options.lineNumber !== undefined ? options.lineNumber : false;
427427
this.noEnd = options.noEnd !== undefined ? options.noEnd : false;
428428
if (options.captionCount !== undefined)
429429
Renderer.captionCount = options.captionCount;
430-
this.titlePrefix = options.titlePrefix || 'Algorithm';
430+
this.titlePrefix = options.titlePrefix !== undefined ? options.titlePrefix : 'Algorithm';
431431
}
432432

433433
RendererOptions.prototype._parseEmVal = function(emVal) {

0 commit comments

Comments
 (0)