Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Commit

Permalink
Better messaging when a processor doesn't export the function correctly.
Browse files Browse the repository at this point in the history
  • Loading branch information
Tim Coulter authored and Tim Coulter committed Sep 1, 2015
1 parent b09144f commit 6c4f6b2
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/build.es6
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,11 @@ var Build = {
return;
}

if (typeof post_processor != "function") {
post_processor_finished(new Error(`Couldn't load custom processor '${processor_name}'; processor function not correctly exported.`));
return;
}

post_processor(memo, target_file, config, Build.process_files, post_processor_finished);
}, function(err, final_post_processed) {
if (err != null) {
Expand Down

0 comments on commit 6c4f6b2

Please sign in to comment.