From 6332196b27472b001f3100dbe36278dd9683aa40 Mon Sep 17 00:00:00 2001 From: Leo Lamprecht Date: Tue, 12 Sep 2017 12:28:33 +0200 Subject: [PATCH] Introduced a much cleaner token name (#837) --- src/providers/sh/commands/login.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/providers/sh/commands/login.js b/src/providers/sh/commands/login.js index 29268f3..90d0774 100644 --- a/src/providers/sh/commands/login.js +++ b/src/providers/sh/commands/login.js @@ -66,7 +66,10 @@ const help = () => { // token: should be used to verify the status of the login process // securityCode: will be sent to the user in the email body const getVerificationData = async ({ apiUrl, email }) => { - const tokenName = `Now CLI ${version} – ${platform()}-${arch()} (${hostname()})` + const hyphens = new RegExp('-', 'g') + const host = hostname().replace(hyphens, ' ').replace('.local', '') + const tokenName = `Now CLI on ${host}` + const data = JSON.stringify({ email, tokenName }) debug('POST /now/registration')