Fix merge logic.

Allow multiple resumes to be merged, extend()-style, and output a
notification for the same.
This commit is contained in:
devlinjd 2015-10-06 16:09:40 -04:00
parent 6abb1ff4d7
commit 0c7325322a
1 changed files with 6 additions and 1 deletions

View File

@ -45,9 +45,14 @@ module.exports = function () {
});
// Merge input resumes
var msg = '';
sheets.length > 1 && (msg += ('Merging ' + sheets[ sheets.length - 1].meta.fileName));
rez = sheets.reduce( function( acc, elem ) {
return extend( true, acc.rep, elem.rep );
msg += (' onto ' + acc.meta.fileName);
return extend( true, acc, elem );
});
sheets.length > 1 && _log( msg );
// Run the transformation!
var finished = targets.map( single );