summaryrefslogtreecommitdiffstats
path: root/Bugzilla/Auth/Verify.pm
diff options
context:
space:
mode:
authormkanat%bugzilla.org <>2006-08-26 07:10:38 +0200
committermkanat%bugzilla.org <>2006-08-26 07:10:38 +0200
commit3120e71d44a272228c0393bfe8be3d4653f2cd82 (patch)
treea867f3d272e48f1aec5dbbef3d530e5f4cd80ae7 /Bugzilla/Auth/Verify.pm
parent3f868ed5858dec2b8523c2997c2ebbb2f379cc7a (diff)
downloadbugzilla-3120e71d44a272228c0393bfe8be3d4653f2cd82.tar.gz
bugzilla-3120e71d44a272228c0393bfe8be3d4653f2cd82.tar.xz
Bug 349349: Use ->create from Bugzilla::Object instead of insert_new_user for Bugzilla::User
Patch By Max Kanat-Alexander <mkanat@bugzilla.org> r=LpSolit, a=myk
Diffstat (limited to 'Bugzilla/Auth/Verify.pm')
-rw-r--r--Bugzilla/Auth/Verify.pm9
1 files changed, 7 insertions, 2 deletions
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