forked from GNUsocial/gnu-social
add static method StatusNet::isHTTPS()
This commit is contained in:
parent
76038fe20c
commit
cef10c7167
@ -169,7 +169,6 @@ class StatusNet
|
||||
return $sites;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Fire initialization events for all instantiated plugins.
|
||||
*/
|
||||
@ -220,7 +219,7 @@ class StatusNet
|
||||
{
|
||||
return self::$is_api;
|
||||
}
|
||||
|
||||
|
||||
public function setApi($mode)
|
||||
{
|
||||
self::$is_api = $mode;
|
||||
@ -368,6 +367,18 @@ class StatusNet
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Are we running from the web with HTTPS?
|
||||
*
|
||||
* @return boolean true if we're running with HTTPS; else false
|
||||
*/
|
||||
|
||||
static function isHTTPS()
|
||||
{
|
||||
// There are some exceptions to this; add them here!
|
||||
return $_SERVER['HTTPS'];
|
||||
}
|
||||
}
|
||||
|
||||
class NoConfigException extends Exception
|
||||
|
Loading…
Reference in New Issue
Block a user