protected function checkSecurity()
    {
        if (!$this->levelSecure || $this->levelSecure === self::BOTH) {
            return true;
        }

        $secure = Request::is('secure');

        return ($this->levelSecure === self::SECURE && $secure) ||
               ($this->levelSecure === self::NONSECURE && !$secure);
    }
protected function checkSecurity()
    {
        if (!$this->levelSecure || $this->levelSecure === self::BOTH) {
            return true;
        }

        $secure = Request::is('secure');

        return ($this->levelSecure === self::SECURE && $secure) ||
               ($this->levelSecure === self::NONSECURE && !$secure);
    }
protected function checkSecurity ( ) { if ( ! $ this -> levelSecure || $ this -> levelSecure === self :: BOTH ) { return true ; } $ secure = Request :: is ( 'secure' ) ; return ( $ this -> levelSecure === self :: SECURE && $ secure ) || ( $ this -> levelSecure === self :: NONSECURE && ! $ secure ) ; }
Method is used for check if HTTPS or HTTP or both

@return bool
Method is used for check if HTTPS or HTTP or both