修正:密码过期强制修改密码的页面,会显示500内部错(使用urllib的unquote函数时,应该是urllib.parse.unquote而不是urllib.unquote)。

dev
Apex Liu 2020-07-01 03:04:46 +08:00
parent 7d05421c8c
commit c863a37094
1 changed files with 2 additions and 1 deletions

View File

@ -5,6 +5,7 @@ import json
import os
import time
import urllib
import urllib.parse
import tornado.gen
from app.base import mail
@ -117,7 +118,7 @@ class ResetPasswordHandler(TPBaseHandler):
class ChangeExpiredPasswordHandler(TPBaseHandler):
def get(self):
_username = urllib.unquote(self.get_argument('username', None))
_username = urllib.parse.unquote(self.get_argument('username', None))
if _username is None:
return self.redirect('/')