diff options
author | mkanat%bugzilla.org <> | 2006-08-11 08:44:49 +0200 |
---|---|---|
committer | mkanat%bugzilla.org <> | 2006-08-11 08:44:49 +0200 |
commit | fb079a1bcf1a9eb442dbd746d787d573a89fdc4a (patch) | |
tree | 644d05740726c4e746f0f77b3cb8b66e49100f39 /Bugzilla/Flag.pm | |
parent | d89140b00e196de6d4d6f2c8e3b163784b5c15ff (diff) | |
download | bugzilla-fb079a1bcf1a9eb442dbd746d787d573a89fdc4a.tar.gz bugzilla-fb079a1bcf1a9eb442dbd746d787d573a89fdc4a.tar.xz |
Bug 347291: Make Bugzilla::User use Bugzilla::Object
Patch By Max Kanat-Alexander <mkanat@bugzilla.org> r=LpSolit, a=myk
Diffstat (limited to 'Bugzilla/Flag.pm')
-rw-r--r-- | Bugzilla/Flag.pm | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/Bugzilla/Flag.pm b/Bugzilla/Flag.pm index 42d747d60..04623524e 100644 --- a/Bugzilla/Flag.pm +++ b/Bugzilla/Flag.pm @@ -330,7 +330,7 @@ sub validate { # We know the requestee exists because we ran # Bugzilla::User::match_field before getting here. - my $requestee = Bugzilla::User->new_from_login($login); + my $requestee = new Bugzilla::User({ name => $login }); # Throw an error if the user can't see the bug. # Note that if permissions on this bug are changed, @@ -593,7 +593,7 @@ sub modify { create({ type => $flag->type, setter => $setter, status => "?", - requestee => Bugzilla::User->new_from_login($login) }, + requestee => new Bugzilla::User({ name => $login }) }, $bug, $attachment, $timestamp); } } @@ -796,7 +796,8 @@ sub FormToNewFlags { push (@flags, { type => $flag_type , setter => $setter , status => $status , - requestee => Bugzilla::User->new_from_login($login) }); + requestee => + new Bugzilla::User({ name => $login }) }); last unless $flag_type->is_multiplicable; } } @@ -843,7 +844,7 @@ sub notify { if (scalar(@bug_in_groups) || $attachment_is_private) { my @new_cc_list; foreach my $cc (split(/[, ]+/, $flag->type->cc_list)) { - my $ccuser = Bugzilla::User->new_from_login($cc) || next; + my $ccuser = new Bugzilla::User({ name => $cc }) || next; next if (scalar(@bug_in_groups) && !$ccuser->can_see_bug($bug->bug_id)); next if $attachment_is_private |