From: Mikael Nordfeldth <mmn@hethane.se>
Date: Sun, 8 Mar 2015 18:17:01 +0000 (+0100)
Subject: Sensitive-test _is_ done in index.php
X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=d6423bbbc82204cb7f64068eb541bcba1f7f2740;p=quix0rs-gnu-social.git

Sensitive-test _is_ done in index.php
---

diff --git a/actions/login.php b/actions/login.php
index 16016f29ec..9c16ad2a07 100644
--- a/actions/login.php
+++ b/actions/login.php
@@ -36,24 +36,6 @@ class LoginAction extends FormAction
 {
     protected $needLogin = false;
 
-    /**
-     * Prepare page to run
-     *
-     *
-     * @param $args
-     * @return string title
-     */
-    protected function prepare(array $args=array())
-    {
-        // @todo this check should really be in index.php for all sensitive actions
-        $ssl = common_config('site', 'ssl');
-        if (empty($_SERVER['HTTPS']) && ($ssl == 'always' || $ssl == 'sometimes')) {
-            common_redirect(common_local_url('login'));
-        }
-
-        return parent::prepare($args);
-    }
-
     /**
      * Handle input, produce output
      *