generator: add existence check to printJoin

This commit is contained in:
Sebastian McKenzie
2014-11-19 12:40:35 +11:00
parent 5fca095149
commit 8f4c4be821

View File

@@ -165,6 +165,8 @@ CodeGenerator.prototype.print = function (node, parent, opts) {
};
CodeGenerator.prototype.printJoin = function (print, nodes, opts) {
if (!nodes || !nodes.length) return;
opts = opts || {};
var self = this;