FIX valid user before register action

This commit is contained in:
jasder 2021-03-05 15:36:26 +08:00
parent 8942c694c4
commit 50928f82c0
1 changed files with 2 additions and 0 deletions

View File

@ -9,6 +9,8 @@ module RegisterHelper
user.platform = platform user.platform = platform
user.activate user.activate
return unless user.valid?
interactor = Gitea::RegisterInteractor.call({username: username, email: email, password: password}) interactor = Gitea::RegisterInteractor.call({username: username, email: email, password: password})
if interactor.success? if interactor.success?
gitea_user = interactor.result gitea_user = interactor.result