]> git.mxchange.org Git - friendica.git/commitdiff
Remove useless theme session variable deletions in modules
authorHypolite Petovan <hypolite@mrpetovan.com>
Sun, 6 Oct 2019 16:08:15 +0000 (12:08 -0400)
committerHypolite Petovan <hypolite@mrpetovan.com>
Sun, 6 Oct 2019 16:08:15 +0000 (12:08 -0400)
mod/community.php
mod/search.php
mod/uimport.php
src/Module/Directory.php
src/Module/Home.php
src/Module/Login.php
src/Module/Register.php

index d29fa729ddf4d109c6c5403954b1547b2722d8f1..81857c6d3a0d64a3cacd78940a0864bf20edaf35 100644 (file)
@@ -17,14 +17,6 @@ use Friendica\Database\DBA;
 use Friendica\Model\Item;
 use Friendica\Model\User;
 
-function community_init(App $a)
-{
-       if (!local_user()) {
-               unset($_SESSION['theme']);
-               unset($_SESSION['mobile-theme']);
-       }
-}
-
 function community_content(App $a, $update = 0)
 {
        $o = '';
index 9ac59502241ae903916d7ca9b873627e89277c33..b28ad7b0e9f58a5efbe18ec8b1a3b6a27384c6f4 100644 (file)
@@ -76,10 +76,6 @@ function search_init(App $a) {
                }
 
                $a->page['aside'] .= search_saved_searches();
-
-       } else {
-               unset($_SESSION['theme']);
-               unset($_SESSION['mobile-theme']);
        }
 }
 
index 22a3161559d46d48cf29149a906a49e6a1de9c2f..436802265b2a85c1dc272534ff1b6ff4db913145 100644 (file)
@@ -41,14 +41,6 @@ function uimport_content(App $a)
                }
        }
 
-
-       if (!empty($_SESSION['theme'])) {
-               unset($_SESSION['theme']);
-       }
-       if (!empty($_SESSION['mobile-theme'])) {
-               unset($_SESSION['mobile-theme']);
-       }
-
        $tpl = Renderer::getMarkupTemplate("uimport.tpl");
        return Renderer::replaceMacros($tpl, [
                '$regbutt' => L10n::t('Import'),
index 7d75e4d477aa0f7cfa4ea5b2601b1074122d433a..1cdd971e8ac21c8753c0b158112b16635473b46d 100644 (file)
@@ -34,9 +34,6 @@ class Directory extends BaseModule
                if (local_user()) {
                        $app->page['aside'] .= Widget::findPeople();
                        $app->page['aside'] .= Widget::follow();
-               } else {
-                       unset($_SESSION['theme']);
-                       unset($_SESSION['mobile-theme']);
                }
 
                $output = '';
index 673701c28d68dfbb3dc1baffd96cc0b32ba9062d..5a1dccde2a7bd0e47c3e8dc55941454d3ff6949f 100644 (file)
@@ -14,14 +14,6 @@ class Home extends BaseModule
 {
        public static function content()
        {
-               if (!empty($_SESSION['theme'])) {
-                       unset($_SESSION['theme']);
-               }
-
-               if (!empty($_SESSION['mobile-theme'])) {
-                       unset($_SESSION['mobile-theme']);
-               }
-
                $app = self::getApp();
                $config = $app->getConfig();
 
index 966ded57faa3b94ffd6b086eb63f165914b7eb16..40e376aeb12f23fb5239eb5f35f418cc332d7946 100644 (file)
@@ -32,9 +32,6 @@ class Login extends BaseModule
        {
                $a = self::getApp();
 
-               Session::remove('theme');
-               Session::remove('mobile-theme');
-
                if (local_user()) {
                        $a->internalRedirect();
                }
index 51287053fdb46519ed4fdd8ade621be10de0ea07..1aabb843937c83fbaca3bac2bf5a567f29dfc1f5 100644 (file)
@@ -61,13 +61,6 @@ class Register extends BaseModule
                        }
                }
 
-               if (!empty($_SESSION['theme'])) {
-                       unset($_SESSION['theme']);
-               }
-               if (!empty($_SESSION['mobile-theme'])) {
-                       unset($_SESSION['mobile-theme']);
-               }
-
                $username   = defaults($_REQUEST, 'username'  , '');
                $email      = defaults($_REQUEST, 'email'     , '');
                $openid_url = defaults($_REQUEST, 'openid_url', '');