]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 1565319 - FF Version selection does not update from client version, shows previou...
authorKohei Yoshino <kohei.yoshino@gmail.com>
Fri, 19 Jul 2019 19:48:46 +0000 (15:48 -0400)
committerGitHub <noreply@github.com>
Fri, 19 Jul 2019 19:48:46 +0000 (15:48 -0400)
enter_bug.cgi
extensions/GuidedBugEntry/web/js/guided.js
post_bug.cgi

index ae3f7c559856611ce2142fcc54afec1c8015edec..9c58f354e634492ef6e4938f73fb7d60495bc879 100755 (executable)
@@ -357,8 +357,6 @@ else {
 #   THEN use the version from the parent bug
 # ELSE IF a version is supplied in the URL
 #   THEN use it
-# ELSE IF there is a version in the cookie
-#   THEN use it (Posting a bug sets a cookie for the current version.)
 # ELSE
 #   The default version is the last one in the list (which, it is
 #   hoped, will be the most recent one).
@@ -367,19 +365,12 @@ else {
 # parameter.
 $vars->{'version'} = $product->versions;
 
-my $version_cookie = $cgi->cookie("VERSION-" . $product->name);
-
 if (($cloned_bug_id) && ($product->name eq $cloned_bug->product)) {
   $default{'version'} = $cloned_bug->version;
 }
 elsif (formvalue('version')) {
   $default{'version'} = formvalue('version');
 }
-elsif (defined $version_cookie
-  and grep { $_->name eq $version_cookie } @{$vars->{'version'}})
-{
-  $default{'version'} = $version_cookie;
-}
 else {
   $default{'version'} = $vars->{'version'}->[$#{$vars->{'version'}}]->name;
 }
index 81370853226b2abca48214fcf7ee3d65b8024e68..fd79f26025b8bfc1f139ee83858a04a1ed0d664c 100644 (file)
@@ -692,10 +692,6 @@ var bugForm = {
         }
       }
     }
-    if (!defaultVersion) {
-      // load last selected version
-      defaultVersion = YAHOO.util.Cookie.get('VERSION-' + productName);
-    }
 
     if (elVersions.length > 1) {
       // more than one version, show select
index de2619900ce8099ddc3d66766fedad42e3981ad6..35d8b815ab9ed4ddf2309304f601ccd083122f99 100755 (executable)
@@ -171,16 +171,6 @@ my $timestamp
   = $dbh->selectrow_array('SELECT creation_ts FROM bugs WHERE bug_id = ?',
   undef, $id);
 
-# Set Version cookie, but only if the user actually selected
-# a version on the page.
-if (defined $cgi->param('version')) {
-  $cgi->send_cookie(
-    -name    => "VERSION-" . $bug->product,
-    -value   => $bug->version,
-    -expires => "Fri, 01-Jan-2038 00:00:00 GMT"
-  );
-}
-
 # We don't have to check if the user can see the bug, because a user filing
 # a bug can always see it. You can't change reporter_accessible until
 # after the bug is filed.