diff --git a/lib/compile_binary_parser.js b/lib/compile_binary_parser.js index 71b1229a25..fef9c63d55 100644 --- a/lib/compile_binary_parser.js +++ b/lib/compile_binary_parser.js @@ -48,7 +48,7 @@ function compile(fields, options, config) { if (typeof options.nestTables == 'string') { tableName = srcEscape(fields[i].table); lvalue = [' this[', srcEscape(fields[i].table + options.nestTables + fields[i].name), ']'].join(''); - } else if (typeof options.nestTables == 'boolean') { + } else if (typeof options.nestTables === true) { tableName = srcEscape(fields[i].table); lvalue = [' this[', tableName, '][', fieldName, ']'].join(''); } else if (options.rowsAsArray) { diff --git a/lib/compile_text_parser.js b/lib/compile_text_parser.js index ac074d0353..fd858e3bf2 100644 --- a/lib/compile_text_parser.js +++ b/lib/compile_text_parser.js @@ -40,7 +40,7 @@ function compile(fields, options, config) { if (typeof options.nestTables == 'string') { tableName = srcEscape(fields[i].table); lvalue = [' this[', srcEscape(fields[i].table + options.nestTables + fields[i].name), ']'].join(''); - } else if (typeof options.nestTables == 'boolean') { + } else if (typeof options.nestTables === true) { tableName = srcEscape(fields[i].table); lvalue = [' this[', tableName, '][', fieldName, ']'].join(''); } else if (options.rowsAsArray) {