mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2025-07-12 03:18:48 +00:00
Remove the use of app function
This commit is contained in:
parent
e823a1bd05
commit
9ad7500146
5 changed files with 20 additions and 6 deletions
|
@ -266,6 +266,9 @@ function twitter_settings(App $a, &$s)
|
|||
if (!local_user()) {
|
||||
return;
|
||||
}
|
||||
|
||||
$user = User::getById(local_user());
|
||||
|
||||
DI::page()['htmlhead'] .= '<link rel="stylesheet" type="text/css" href="' . DI::baseUrl()->get() . '/addon/twitter/twitter.css' . '" media="all" />' . "\r\n";
|
||||
/* * *
|
||||
* 1) Check that we have global consumer key & secret
|
||||
|
@ -356,7 +359,7 @@ function twitter_settings(App $a, &$s)
|
|||
$s .= Renderer::replaceMacros($field_checkbox, [
|
||||
'$field' => ['twitter-enable', DI::l10n()->t('Allow posting to Twitter'), $enabled, DI::l10n()->t('If enabled all your <strong>public</strong> postings can be posted to the associated Twitter account. You can choose to do so by default (here) or for every posting separately in the posting options when writing the entry.')]
|
||||
]);
|
||||
if ($a->getUserValue('hidewall')) {
|
||||
if ($user['hidewall']) {
|
||||
$s .= '<p>' . DI::l10n()->t('<strong>Note</strong>: Due to your privacy settings (<em>Hide your profile details from unknown viewers?</em>) the link potentially included in public postings relayed to Twitter will lead the visitor to a blank page informing the visitor that the access to your profile has been restricted.') . '</p>';
|
||||
}
|
||||
$s .= Renderer::replaceMacros($field_checkbox, [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue