From fa591e5c9b27752bbe55c28cb3f7f798558104a6 Mon Sep 17 00:00:00 2001 From: syuilo Date: Fri, 6 Jan 2017 01:28:16 +0900 Subject: アクセストークンは i に統一 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit トークンの先頭に ! がプリフィックスされているかどうかでユーザー固有のトークンかどうか判別する --- src/api/private/signup.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/api/private') diff --git a/src/api/private/signup.ts b/src/api/private/signup.ts index c50b070052..592dfcceb1 100644 --- a/src/api/private/signup.ts +++ b/src/api/private/signup.ts @@ -48,7 +48,7 @@ export default async (req: express.Request, res: express.Response) => { const hash = bcrypt.hashSync(password, salt); // Generate secret - const secret = rndstr('a-zA-Z0-9', 32); + const secret = '!' + rndstr('a-zA-Z0-9', 32); // Create account const inserted = await User.insert({ -- cgit v1.2.3-freya