}
if (DI::args()->getArgc() > 1 && DI::args()->getArgv()[1] == 'help') {
- $lang = $a->user['language'];
+ $lang = $a->getUserValue('language');
$default_dir = 'addon/advancedcontentfilter/doc/';
$help_file = 'advancedcontentfilter.md';
$s .= '<div id="ifttt-configuration-wrapper">';
$s .= '<p>' . DI::l10n()->t('Create an account at <a href="http://www.ifttt.com">IFTTT</a>. Create three Facebook recipes that are connected with <a href="https://ifttt.com/maker">Maker</a> (In the form "if Facebook then Maker") with the following parameters:') . '</p>';
$s .= '<h4>URL</h4>';
- $s .= '<p>' . DI::baseUrl()->get() . '/ifttt/' . $a->user['nickname'] . '</p>';
+ $s .= '<p>' . DI::baseUrl()->get() . '/ifttt/' . $a->getNickname() . '</p>';
$s .= '<h4>Method</h4>';
$s .= '<p>POST</p>';
$s .= '<h4>Content Type</h4>';
}
if (($username == "") && DI::config()->get("jappixmini", "default_user")) {
- $username = $a->user["nickname"];
+ $username = $a->getNickname();
}
$info_text = DI::config()->get("jappixmini", "infotext");
// Never filter own messages
// TODO: find a better way to extract this
- $logged_user_profile = DI::baseUrl()->get() . '/profile/' . $a->user['nickname'];
+ $logged_user_profile = DI::baseUrl()->get() . '/profile/' . $a->getNickname();
if ($logged_user_profile == $hook_data['item']['author-link']) {
return;
}
$head = $xml->createElement('head');
$body = $xml->createElement('body');
$outline = $xml->createElement('outline');
- $outline->setAttribute('title', $a->user['username'] . '\'s RSS/Atom contacts');
- $outline->setAttribute('text', $a->user['username'] . '\'s RSS/Atom contacts');
+ $outline->setAttribute('title', $a->getUserValue('username') . '\'s RSS/Atom contacts');
+ $outline->setAttribute('text', $a->getUserValue('username') . '\'s RSS/Atom contacts');
foreach($data as $c) {
$entry = $xml->createElement('outline');
// enable addon for test
$pConfig->set(local_user(), 'securemail', 'enable', 1);
- parent::__construct($sitename, $sender_email, $sender_email, $a->user['email'],
+ parent::__construct($sitename, $sender_email, $sender_email, $a->getUserValue('email'),
$subject, "<p>{$message}</p>", $message,
[], local_user());
}
$s .= '<div id="statusnet-info" ><img id="statusnet-avatar" src="' . $details->profile_image_url . '" /><p id="statusnet-info-block">' . DI::l10n()->t('Currently connected to: ') . '<a href="' . $details->statusnet_profile_url . '" target="_statusnet">' . $details->screen_name . '</a><br /><em>' . $details->description . '</em></p></div>';
}
$s .= '<p>' . DI::l10n()->t('If enabled all your <strong>public</strong> postings can be posted to the associated GNU Social account. You can choose to do so by default (here) or for every posting separately in the posting options when writing the entry.') . '</p>';
- if ($a->user['hidewall']) {
+ if ($a->getUserValue('hidewall')) {
$s .= '<p>' . DI::l10n()->t('<strong>Note</strong>: Due your privacy settings (<em>Hide your profile details from unknown viewers?</em>) the link potentially included in public postings relayed to GNU Social will lead the visitor to a blank page informing the visitor that the access to your profile has been restricted.') . '</p>';
}
$s .= '<div id="statusnet-enable-wrapper">';
$nickname = preg_replace("=https?://twitter.com/(.*)=ism", "$1", $contact["url"]);
$nickname = str_replace("@twitter.com", "", $nickname);
- $uid = $a->user["uid"];
+ $uid = $a->getUserId();
$ckey = DI::config()->get('twitter', 'consumerkey');
$csecret = DI::config()->get('twitter', 'consumersecret');
$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->user['hidewall']) {
+ if ($a->getUserValue('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, [
DI::auth()->setForUser($a, $record);
DI::session()->set('allow_api', true);
- Hook::callAll('logged_in', $a->user);
+ Hook::callAll('logged_in', $record);
}
DI::pConfig()->set(local_user(), "xmpp", "password", $password);
}
- $jid = $a->user["nickname"] . "@" . DI::baseUrl()->getHostname() . "/converse-" . Strings::getRandomHex(5);
+ $jid = $a->getNickname() . "@" . DI::baseUrl()->getHostname() . "/converse-" . Strings::getRandomHex(5);
$auto_login = "auto_login: true,
authentication: 'login',