File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed
velog-backend/src/router/auth Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -20,7 +20,6 @@ import UserMeta from '../../database/models/UserMeta';
2020
2121const s3 = new AWS . S3 ( { region : 'ap-northeast-2' , signatureVersion : 'v4' } ) ;
2222
23-
2423export const sendAuthEmail = async ( ctx : Context ) : Promise < * > => {
2524 type BodySchema = {
2625 email : string ,
@@ -44,7 +43,8 @@ export const sendAuthEmail = async (ctx: Context): Promise<*> => {
4443 }
4544
4645 try {
47- const { email } : BodySchema = ( ctx . request . body : any ) ;
46+ const { email : rawEmail } : BodySchema = ( ctx . request . body : any ) ;
47+ const email = rawEmail . toLowerCase ( ) ;
4848
4949 // TODO: check email existancy
5050 const user = await User . findUser ( 'email' , email ) ;
@@ -280,7 +280,6 @@ export const createLocalAccount = async (ctx: Context): Promise<*> => {
280280 token,
281281 } ;
282282
283-
284283 setTimeout ( ( ) => {
285284 UserMeta . build ( {
286285 fk_user_id : user . id ,
You can’t perform that action at this time.
0 commit comments