mirror of
https://github.com/mdgriffith/elm-optimize-level-2.git
synced 2024-11-25 22:50:42 +03:00
Throw an error when input is not a JS/Elm file
This commit is contained in:
parent
6e36e78637
commit
c33c280e09
@ -79,9 +79,7 @@ export async function run(
|
||||
process.exit(1)
|
||||
}
|
||||
} else {
|
||||
console.error('Please provide a path to an Elm file.');
|
||||
program.outputHelp();
|
||||
return;
|
||||
throw new Error('Please provide a path to an Elm file.\n' + program.helpInformation());
|
||||
}
|
||||
if (jsSource != '') {
|
||||
const transformed = await Transform.transform(
|
||||
|
Loading…
Reference in New Issue
Block a user