Browse Source

FIX register with validate email

pull/278/head
Jasder 5 years ago
parent
commit
e5a46a242f
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      app/controllers/concerns/register_helper.rb

+ 1
- 1
app/controllers/concerns/register_helper.rb View File

@@ -3,7 +3,7 @@ module RegisterHelper

def autologin_register(username, email, password, platform= 'forge')
result = {message: nil, user: nil}
email ||= "#{username}@example.org"
email = email.blank? ? "#{username}@example.org" : email

user = User.find_by(login: username)
user ||= User.new(admin: false, login: username, mail: email, type: "User")


Loading…
Cancel
Save