From 3120e71d44a272228c0393bfe8be3d4653f2cd82 Mon Sep 17 00:00:00 2001 From: "mkanat%bugzilla.org" <> Date: Sat, 26 Aug 2006 05:10:38 +0000 Subject: Bug 349349: Use ->create from Bugzilla::Object instead of insert_new_user for Bugzilla::User Patch By Max Kanat-Alexander r=LpSolit, a=myk --- Bugzilla/Auth/Verify.pm | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'Bugzilla/Auth') diff --git a/Bugzilla/Auth/Verify.pm b/Bugzilla/Auth/Verify.pm index 952998caf..52cebb5ea 100644 --- a/Bugzilla/Auth/Verify.pm +++ b/Bugzilla/Auth/Verify.pm @@ -77,8 +77,13 @@ sub create_or_update_user { || return { failure => AUTH_ERROR, error => 'auth_invalid_email', details => {addr => $username} }; - insert_new_user($username, $real_name, $password); - $username_user_id = login_to_id($username); + # XXX Theoretically this could fail with an error, but the fix for + # that is too involved to be done right now. + my $user = Bugzilla::User->create({ + login_name => $username, + cryptpassword => $password, + realname => $real_name}); + $username_user_id = $user->id; } # If we have a valid username id and an extern_id, but no valid -- cgit v1.2.3-24-g4f1b