Commit 14ef3fcf authored by Dan Zajdband's avatar Dan Zajdband

Only console error

parent 37f76b16
...@@ -27,10 +27,11 @@ clean(dir) ...@@ -27,10 +27,11 @@ clean(dir)
// Check if pages dir exists and warn if not // Check if pages dir exists and warn if not
if (!(await exists(join(dir, 'pages')))) { if (!(await exists(join(dir, 'pages')))) {
if (await exists(join(dir, '..', 'pages'))) { if (await exists(join(dir, '..', 'pages'))) {
throw new Error('> No `pages` directory found. Did you mean to run `next` in the parent (`../`) directory?') console.error('> No `pages` directory found. Did you mean to run `next` in the parent (`../`) directory?')
} else { } else {
throw new Error('> Couldn\'t find a `pages` directory. Please create one under the project root') console.error('> Couldn\'t find a `pages` directory. Please create one under the project root')
} }
exit(1)
} }
}) })
.catch((err) => { .catch((err) => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment