Trac importer: handle nil usernames.
git-svn-id: http://redmine.rubyforge.org/svn/trunk@1125 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
68d3305ae2
commit
943ba3e34f
|
@ -157,6 +157,8 @@ namespace :redmine do
|
|||
end
|
||||
|
||||
def self.find_or_create_user(username, project_member = false)
|
||||
return User.anonymous if username.blank?
|
||||
|
||||
u = User.find_by_login(username)
|
||||
if !u
|
||||
# Create a new user if not found
|
||||
|
|
Loading…
Reference in New Issue