This commit is contained in:
sylor_huang@126.com 2020-03-17 14:45:00 +08:00
parent 7877217eed
commit a3672cd036
1 changed files with 1 additions and 2 deletions

View File

@ -68,8 +68,7 @@ class SyncForgeJob < ApplicationJob
owner_params = owner_params&.except!(*keys_to_delete) owner_params = owner_params&.except!(*keys_to_delete)
user_password = random_password user_password = random_password
new_user = [] new_user = []
new_user = User.new(owner_params.merge(platform: platform))
interactor = Gitea::RegisterInteractor.call({username: owner_params["login"], email: owner_params["mail"], password: user_password})
if owner_params.present? if owner_params.present?
if User.exists?(login: owner_params["login"]) if User.exists?(login: owner_params["login"])
new_user = User.find_by(login: owner_params["login"]) new_user = User.find_by(login: owner_params["login"])