[DRE-commits] [SCM] redmine.git branch, master-experimental, updated. debian/1.4.4+dfsg1-1-5-g7f1f228

Jérémy Lal kapouer at melix.org
Thu Oct 11 10:25:08 UTC 2012


The following commit has been merged in the master-experimental branch:
commit 16c0cd511a5a2082f393512dcd62ee7f147e7803
Author: Jérémy Lal <kapouer at melix.org>
Date:   Thu Sep 1 21:49:47 2011 +0200

    Fix autologin with rake 1.3.1 (Closes: #637486)

diff --git a/debian/patches/1013_cookie_symbol_to_s.patch b/debian/patches/1013_cookie_symbol_to_s.patch
new file mode 100644
index 0000000..b5e2baf
--- /dev/null
+++ b/debian/patches/1013_cookie_symbol_to_s.patch
@@ -0,0 +1,24 @@
+Description: Cookie values need to be strings in some rails/rake versions.
+Bug-Redmine: http://www.redmine.org/issues/9118
+Author: Eduardo Rocha <folhabranca at gmail.com>, David Martínez Moreno <ender at debian.org>
+Last-Update: 2011-09-01
+--- a/app/controllers/account_controller.rb
++++ b/app/controllers/account_controller.rb
+@@ -129,7 +129,7 @@
+   
+   def logout_user
+     if User.current.logged?
+-      cookies.delete :autologin
++      cookies.delete :autologin.to_s
+       Token.delete_all(["user_id = ? AND action = ?", User.current.id, 'autologin'])
+       self.logged_user = nil
+     end
+@@ -204,7 +204,7 @@
+     # generate a key and set cookie if autologin
+     if params[:autologin] && Setting.autologin?
+       token = Token.create(:user => user, :action => 'autologin')
+-      cookies[:autologin] = { :value => token.value, :expires => 1.year.from_now }
++      cookies[:autologin.to_s] = { :value => token.value, :expires => 1.year.from_now }
+     end
+     call_hook(:controller_account_success_authentication_after, {:user => user })
+     redirect_back_or_default :controller => 'my', :action => 'page'
diff --git a/debian/patches/1013_logout_cookie_rake.patch b/debian/patches/1013_logout_cookie_rake.patch
deleted file mode 100644
index a118c84..0000000
--- a/debian/patches/1013_logout_cookie_rake.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Description: Cookie values need to be strings in some rails/rake versions.
-Bug-Redmine: http://www.redmine.org/issues/9118
-Author: Eduardo Rocha <folhabranca at gmail.com>
-Last-Update: 2011-08-14
---- a/app/controllers/account_controller.rb.orig	2011-08-24 11:41:33.000000000 -0300
-+++ b/app/controllers/account_controller.rb	2011-08-24 09:21:00.000000000 -0300
-@@ -129,7 +129,7 @@
-   
-   def logout_user
-     if User.current.logged?
--      cookies.delete :autologin
-+      cookies.delete :autologin.to_s
-       Token.delete_all(["user_id = ? AND action = ?", User.current.id, 'autologin'])
-       self.logged_user = nil
-     end
diff --git a/debian/patches/series b/debian/patches/series
index 419833d..c6e9819 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -7,5 +7,5 @@
 2008_force_table_encoding_mysql.patch
 2009_FHS_thin_config.patch
 2010_use_i18n_0.4.1.patch
-1013_logout_cookie_rake.patch
+1013_cookie_symbol_to_s.patch
 1014_send_CSRF_ajax.patch

-- 
redmine.git



More information about the Pkg-ruby-extras-commits mailing list