cleanup ssl_policy implementation
This commit is contained in:
parent
f970d9ab4d
commit
a362dc46e3
1 changed files with 4 additions and 4 deletions
8
boot.php
8
boot.php
|
@ -17,7 +17,7 @@ define ( 'DOWN_ARROW', '⇩' );
|
||||||
|
|
||||||
define ( 'SSL_POLICY_NONE', 0 );
|
define ( 'SSL_POLICY_NONE', 0 );
|
||||||
define ( 'SSL_POLICY_FULL', 1 );
|
define ( 'SSL_POLICY_FULL', 1 );
|
||||||
define ( 'SSL_POLICY_SELFSIGN' 2 );
|
define ( 'SSL_POLICY_SELFSIGN', 2 );
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -280,8 +280,8 @@ class App {
|
||||||
}
|
}
|
||||||
|
|
||||||
function get_baseurl($ssl = false) {
|
function get_baseurl($ssl = false) {
|
||||||
if(strlen($this->baseurl))
|
// if(strlen($this->baseurl))
|
||||||
return $this->baseurl;
|
// return $this->baseurl;
|
||||||
|
|
||||||
$scheme = $this->scheme;
|
$scheme = $this->scheme;
|
||||||
|
|
||||||
|
@ -290,7 +290,7 @@ class App {
|
||||||
if(($a->config['ssl_policy'] == SSL_POLICY_SELFSIGN) && (local_user() || x($_POST,'auth-params')))
|
if(($a->config['ssl_policy'] == SSL_POLICY_SELFSIGN) && (local_user() || x($_POST,'auth-params')))
|
||||||
$scheme = 'https';
|
$scheme = 'https';
|
||||||
|
|
||||||
$this->baseurl = ( $scheme . "://" . $this->hostname . ((isset($this->path) && strlen($this->path)) ? '/' . $this->path : '' );
|
$this->baseurl = $scheme . "://" . $this->hostname . ((isset($this->path) && strlen($this->path)) ? '/' . $this->path : '' );
|
||||||
return $this->baseurl;
|
return $this->baseurl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue