diff --git a/settings/apps.php b/settings/apps.php
index 6021574cbb35c25c09826ed83fa9a3fa54d9db3c..b725c87b0abfaab8e6e6ecac160c6b47218cdced 100644
--- a/settings/apps.php
+++ b/settings/apps.php
@@ -22,6 +22,7 @@
 */
 
 OC_Util::checkAdminUser();
+\OC::$server->getSession()->close();
 
 // Load the files we need
 OCP\Util::addStyle('settings', 'settings' );