From 3300f959b1ae3968370f187598fbb84077e1453a Mon Sep 17 00:00:00 2001
From: vogelor <vogelor@ispconfig3>
Date: Mon, 15 Dec 2008 10:08:09 -0500
Subject: [PATCH] Fixed a bug in "login as". Now the user can "re-login" as admin.

---
 interface/web/login/index.php |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/interface/web/login/index.php b/interface/web/login/index.php
index 5e9eb68..3698f08 100644
--- a/interface/web/login/index.php
+++ b/interface/web/login/index.php
@@ -111,7 +111,7 @@
 		                	$sql = "DELETE FROM `attempts_login` WHERE `ip`='{$ip}'";
 		                	$app->db->query($sql);
 		                	$user = $app->db->toLower($user);
-							if ($loginAs) $oldSession = $_SESSION['s_old'];
+							if ($loginAs) $oldSession = $_SESSION['s'];
 		                    $_SESSION = array();
 							if ($loginAs) $_SESSION['s_old'] = $oldSession; // keep the way back!
 		                    $_SESSION['s']['user'] = $user;

--
Gitblit v1.9.1