[Svn] r4428 - trunk/roundcubemail

trac at roundcube.net trac at roundcube.net
Wed Jan 19 14:11:47 CET 2011


Author: thomasb
Date: 2011-01-19 07:11:47 -0600 (Wed, 19 Jan 2011)
New Revision: 4428

Modified:
   trunk/roundcubemail/index.php
Log:
Better fix for login redirect, don't force mail task

Modified: trunk/roundcubemail/index.php
===================================================================
--- trunk/roundcubemail/index.php	2011-01-19 12:58:10 UTC (rev 4427)
+++ trunk/roundcubemail/index.php	2011-01-19 13:11:47 UTC (rev 4428)
@@ -105,11 +105,16 @@
 
     // restore original request parameters
     $query = array();
-    if ($url = get_input_value('_url', RCUBE_INPUT_POST))
+    if ($url = get_input_value('_url', RCUBE_INPUT_POST)) {
       parse_str($url, $query);
+      
+      // prevent endless looping on login page
+      if ($query['_task'] == 'login')
+        unset($query['_task']);
+    }
 
     // allow plugins to control the redirect url after login success
-    $redir = $RCMAIL->plugins->exec_hook('login_after', array('_task' => 'mail') + $query);
+    $redir = $RCMAIL->plugins->exec_hook('login_after', $query + array('_task' => 'mail'));
     unset($redir['abort']);
 
     // send redirect

_______________________________________________
http://lists.roundcube.net/mailman/listinfo/svn



More information about the Svn mailing list