diff options
author | Max Kanat-Alexander <mkanat@bugzilla.org> | 2010-05-14 16:25:05 +0200 |
---|---|---|
committer | Max Kanat-Alexander <mkanat@bugzilla.org> | 2010-05-14 16:25:05 +0200 |
commit | 7072d6a673f9a05b688d07e05980b7932c7abbe6 (patch) | |
tree | a0356451566ff1a744714c8fcadf040cb9b20e2a /Bugzilla/CGI.pm | |
parent | 80130158d4f4baa47cf1212cf28da1dc84b9d096 (diff) | |
download | bugzilla-7072d6a673f9a05b688d07e05980b7932c7abbe6.tar.gz bugzilla-7072d6a673f9a05b688d07e05980b7932c7abbe6.tar.xz |
Bug 561296: A fix allowing updating a field value's name when it is
the default value
r=LpSolit, a=LpSolit
Diffstat (limited to 'Bugzilla/CGI.pm')
-rw-r--r-- | Bugzilla/CGI.pm | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Bugzilla/CGI.pm b/Bugzilla/CGI.pm index 75b7f18d7..00f23c393 100644 --- a/Bugzilla/CGI.pm +++ b/Bugzilla/CGI.pm @@ -329,6 +329,14 @@ sub _fix_utf8 { return $input; } +sub should_set { + my ($self, $param) = @_; + my $set = (defined $self->param($param) + or defined $self->param("defined_$param")) + ? 1 : 0; + return $set; +} + # The various parts of Bugzilla which create cookies don't want to have to # pass them around to all of the callers. Instead, store them locally here, # and then output as required from |header|. |