fix: 修改密码没有发通知

pull/6814/head
xinwen 2021-09-13 10:56:55 +08:00 committed by Jiangjie.Bai
parent 4fe715d953
commit f8f783745c
1 changed files with 5 additions and 0 deletions

View File

@ -72,6 +72,11 @@ class UserPasswordApi(generics.RetrieveUpdateAPIView):
def get_object(self):
return self.request.user
def update(self, request, *args, **kwargs):
resp = super().update(request, *args, **kwargs)
ResetPasswordSuccessMsg(self.request.user, request).publish_async()
return resp
class UserPublicKeyApi(generics.RetrieveUpdateAPIView):
permission_classes = (IsAuthenticated,)