don't try and set a blank sis_user_id for pseudonyms created via the browser

Change-Id: If0a88867faef6b838517d65b70b828fc80715582
Reviewed-on: https://gerrit.instructure.com/4295
Tested-by: Hudson <hudson@instructure.com>
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
This commit is contained in:
Cody Cutrer 2011-06-20 13:39:04 -06:00
parent d590384c6b
commit ea2f9ffdd8
1 changed files with 1 additions and 0 deletions

View File

@ -262,6 +262,7 @@ class PseudonymsController < ApplicationController
params[:pseudonym][:account] = Account.root_accounts.find(account_id)
end
params[:pseudonym][:account] ||= @domain_root_account
params[:pseudonym].delete(:sis_user_id) if params[:pseudonym][:sis_user_id].blank?
@pseudonym = @user.pseudonyms.build(params[:pseudonym])
unless @pseudonym.account && @pseudonym.account.settings[:admins_can_change_passwords]
params[:pseudonym].delete :password