|
|
@ -179,14 +179,14 @@ function main() { |
|
|
|
try { |
|
|
|
try { |
|
|
|
var baselineFile = fs.readFileSync(options.baseline).toString(); |
|
|
|
var baselineFile = fs.readFileSync(options.baseline).toString(); |
|
|
|
baseline = flatten(JSON.parse(baselineFile)); |
|
|
|
baseline = flatten(JSON.parse(baselineFile)); |
|
|
|
} catch(e) { |
|
|
|
} catch (e) { |
|
|
|
console.log('Error reading file "' + options.baseline + '": ' + e); |
|
|
|
console.log('Error reading file "' + options.baseline + '": ' + e); |
|
|
|
process.exit(0); |
|
|
|
process.exit(0); |
|
|
|
} |
|
|
|
} |
|
|
|
try { |
|
|
|
try { |
|
|
|
var currentFile = fs.readFileSync(options.current).toString(); |
|
|
|
var currentFile = fs.readFileSync(options.current).toString(); |
|
|
|
current = flatten(JSON.parse(currentFile)); |
|
|
|
current = flatten(JSON.parse(currentFile)); |
|
|
|
} catch(e) { |
|
|
|
} catch (e) { |
|
|
|
console.log('Error reading file "' + options.current + '": ' + e); |
|
|
|
console.log('Error reading file "' + options.current + '": ' + e); |
|
|
|
process.exit(0); |
|
|
|
process.exit(0); |
|
|
|
} |
|
|
|
} |
|
|
|