rt 4.2.14 (#13852)
[freeside.git] / rt / share / html / REST / 1.0 / logout
index a6b0bac..a62e684 100755 (executable)
@@ -2,7 +2,7 @@
 %#
 %# COPYRIGHT:
 %#
-%# This software is Copyright (c) 1996-2011 Best Practical Solutions, LLC
+%# This software is Copyright (c) 1996-2017 Best Practical Solutions, LLC
 %#                                          <sales@bestpractical.com>
 %#
 %# (Except where explicitly superseded by other copyright notices)
@@ -46,6 +46,9 @@
 %#
 %# END BPS TAGGED BLOCK }}}
 <%PERL>
-tied(%session)->delete if (defined %session);
+if (keys %session) {
+    RT::Interface::Web::InstantiateNewSession();
+    $session{CurrentUser} = RT::CurrentUser->new();
+}
 </%PERL>
 RT/<% $RT::VERSION %> 200 Ok