Fix: Force baseUrl being a string
This commit is contained in:
parent
68d9e1f33c
commit
b0f880d0eb
|
@ -94,7 +94,7 @@ HELP;
|
||||||
|
|
||||||
$this->out(sprintf('Relocation started from %s to %s. Could take a while to complete.', $this->baseUrl, $this->getArgument(0)));
|
$this->out(sprintf('Relocation started from %s to %s. Could take a while to complete.', $this->baseUrl, $this->getArgument(0)));
|
||||||
|
|
||||||
$old_url = $this->baseUrl;
|
$old_url = (string)$this->baseUrl;
|
||||||
|
|
||||||
// Generate host names for relocation the addresses in the format user@address.tld
|
// Generate host names for relocation the addresses in the format user@address.tld
|
||||||
$new_host = str_replace('http://', '@', Strings::normaliseLink($new_url));
|
$new_host = str_replace('http://', '@', Strings::normaliseLink($new_url));
|
||||||
|
|
|
@ -343,7 +343,7 @@ class Install extends BaseModule
|
||||||
*/
|
*/
|
||||||
private function whatNext(): string
|
private function whatNext(): string
|
||||||
{
|
{
|
||||||
$baseurl = $this->baseUrl;
|
$baseurl = (string)$this->baseUrl;
|
||||||
return
|
return
|
||||||
$this->t('<h1>What next</h1>')
|
$this->t('<h1>What next</h1>')
|
||||||
. "<p>" . $this->t('IMPORTANT: You will need to [manually] setup a scheduled task for the worker.')
|
. "<p>" . $this->t('IMPORTANT: You will need to [manually] setup a scheduled task for the worker.')
|
||||||
|
|
|
@ -232,7 +232,7 @@ class Import extends \Friendica\BaseModule
|
||||||
}
|
}
|
||||||
|
|
||||||
$oldBaseUrl = $account['baseurl'];
|
$oldBaseUrl = $account['baseurl'];
|
||||||
$newBaseUrl = $this->baseUrl;
|
$newBaseUrl = (string)$this->baseUrl;
|
||||||
|
|
||||||
$oldAddr = str_replace('http://', '@', Strings::normaliseLink($oldBaseUrl));
|
$oldAddr = str_replace('http://', '@', Strings::normaliseLink($oldBaseUrl));
|
||||||
$newAddr = str_replace('http://', '@', Strings::normaliseLink($newBaseUrl));
|
$newAddr = str_replace('http://', '@', Strings::normaliseLink($newBaseUrl));
|
||||||
|
|
|
@ -105,7 +105,7 @@ class Xrd extends BaseModule
|
||||||
|
|
||||||
private function printSystemJSON(array $owner)
|
private function printSystemJSON(array $owner)
|
||||||
{
|
{
|
||||||
$baseURL = $this->baseUrl;
|
$baseURL = (string)$this->baseUrl;
|
||||||
$json = [
|
$json = [
|
||||||
'subject' => 'acct:' . $owner['addr'],
|
'subject' => 'acct:' . $owner['addr'],
|
||||||
'aliases' => [$owner['url']],
|
'aliases' => [$owner['url']],
|
||||||
|
@ -151,7 +151,7 @@ class Xrd extends BaseModule
|
||||||
|
|
||||||
private function printJSON(string $alias, array $owner, array $avatar)
|
private function printJSON(string $alias, array $owner, array $avatar)
|
||||||
{
|
{
|
||||||
$baseURL = $this->baseUrl;
|
$baseURL = (string)$this->baseUrl;
|
||||||
|
|
||||||
$json = [
|
$json = [
|
||||||
'subject' => 'acct:' . $owner['addr'],
|
'subject' => 'acct:' . $owner['addr'],
|
||||||
|
@ -228,7 +228,7 @@ class Xrd extends BaseModule
|
||||||
|
|
||||||
private function printXML(string $alias, array $owner, array $avatar)
|
private function printXML(string $alias, array $owner, array $avatar)
|
||||||
{
|
{
|
||||||
$baseURL = $this->baseUrl;
|
$baseURL = (string)$this->baseUrl;
|
||||||
|
|
||||||
$xmlString = XML::fromArray([
|
$xmlString = XML::fromArray([
|
||||||
'XRD' => [
|
'XRD' => [
|
||||||
|
|
|
@ -264,7 +264,7 @@ class Notify extends BaseRepository
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$siteurl = $this->baseUrl;
|
$siteurl = (string)$this->baseUrl;
|
||||||
$sitename = $this->config->get('config', 'sitename');
|
$sitename = $this->config->get('config', 'sitename');
|
||||||
|
|
||||||
// with $params['show_in_notification_page'] == false, the notification isn't inserted into
|
// with $params['show_in_notification_page'] == false, the notification isn't inserted into
|
||||||
|
@ -807,7 +807,7 @@ class Notify extends BaseRepository
|
||||||
$epreamble = $msg['rich'];
|
$epreamble = $msg['rich'];
|
||||||
|
|
||||||
$sitename = $this->config->get('config', 'sitename');
|
$sitename = $this->config->get('config', 'sitename');
|
||||||
$siteurl = $this->baseUrl;
|
$siteurl = (string)$this->baseUrl;
|
||||||
|
|
||||||
$sitelink = $l10n->t('Please visit %s to view and/or reply to the conversation.');
|
$sitelink = $l10n->t('Please visit %s to view and/or reply to the conversation.');
|
||||||
$tsitelink = sprintf($sitelink, $siteurl);
|
$tsitelink = sprintf($sitelink, $siteurl);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user