Showing
1 changed file
with
11 additions
and
0 deletions
@@ -242,7 +242,18 @@ const local = { | @@ -242,7 +242,18 @@ const local = { | ||
242 | }); | 242 | }); |
243 | } | 243 | } |
244 | 244 | ||
245 | + if (req.session.hasGetSMS) { | ||
246 | + return res.json({ | ||
247 | + code: 400, | ||
248 | + message: '发送失败' | ||
249 | + }); | ||
250 | + } | ||
251 | + | ||
245 | LoginService.sendPasswordBySMS(area, mobile).then((result) => { | 252 | LoginService.sendPasswordBySMS(area, mobile).then((result) => { |
253 | + if (result && result.code === 200) { | ||
254 | + req.session.hasGetSMS = true; | ||
255 | + } | ||
256 | + | ||
246 | return res.json(result); | 257 | return res.json(result); |
247 | }).catch(next); | 258 | }).catch(next); |
248 | }, | 259 | }, |
-
Please register or login to post a comment