Browse Source

tweak error messages

master
Guillermo Rauch 9 years ago
parent
commit
7d9ffcb45b
  1. 4
      lib/alias.js

4
lib/alias.js

@ -160,13 +160,13 @@ export default class Alias extends Now {
const code = body.error.code; const code = body.error.code;
if ('custom_domain_needs_upgrade' === code) { if ('custom_domain_needs_upgrade' === code) {
const err = new Error(`You are attempting to use a custom domain alias (${chalk.underline(chalk.cyan(alias))}), but this is only enabled for premium accounts. Please upgrade at ${chalk.underline('https://zeit.co/account')}`); const err = new Error(`Custom domains are only enabled for premium accounts. Please upgrade at ${chalk.underline('https://zeit.co/account')}.`);
err.userError = true; err.userError = true;
return bail(err); return bail(err);
} }
if ('alias_in_use' === code) { if ('alias_in_use' === code) {
const err = new Error(`The alias you are trying to configure (${chalk.underline(chalk.cyan(alias))}) is already in use by a different account.`); const err = new Error(`The alias you are trying to configure (${chalk.underline(chalk.bold(alias))}) is already in use by a different account.`);
err.userError = true; err.userError = true;
return bail(err); return bail(err);
} }

Loading…
Cancel
Save