- /**
- * Returns the scheme of the current call
- *
- * @return string
- *
- * @deprecated 2019.06 - use BaseURL->getScheme() instead
- */
- public function getScheme()
- {
- return $this->baseURL->getScheme();
- }
-
- /**
- * Retrieves the Friendica instance base URL
- *
- * @param bool $ssl Whether to append http or https under BaseURL::SSL_POLICY_SELFSIGN
- *
- * @return string Friendica server base URL
- *
- * @deprecated 2019.09 - use BaseUrl->get($ssl) instead
- */
- public function getBaseURL($ssl = false)
- {
- return $this->baseURL->get($ssl);
- }
-
- /**
- * Returns the current UserAgent as a String
- *
- * @return string the UserAgent as a String
- * @throws HTTPException\InternalServerErrorException
- */
- public function getUserAgent()
- {
- return
- FRIENDICA_PLATFORM . " '" .
- FRIENDICA_CODENAME . "' " .
- FRIENDICA_VERSION . '-' .
- DB_UPDATE_VERSION . '; ' .
- $this->getBaseURL();
- }
-
- /**
- * Generates the site's default sender email address
- *
- * @return string
- * @throws HTTPException\InternalServerErrorException
- */
- public function getSenderEmailAddress()
- {
- $sender_email = $this->config->get('config', 'sender_email');
- if (empty($sender_email)) {
- $hostname = $this->baseURL->getHostname();
- if (strpos($hostname, ':')) {
- $hostname = substr($hostname, 0, strpos($hostname, ':'));
- }
-
- $sender_email = 'noreply@' . $hostname;
- }
-
- return $sender_email;
- }
-