use Friendica\Core\System;
use Friendica\Database\DBA;
use Friendica\DI;
+use Friendica\Model\Group;
use Friendica\Module\BaseApi;
/**
DI::mstdnError()->UnprocessableEntity();
}
- return Group::addMembers($this->parameters['id'], $request['account_ids']);
+ Group::addMembers($this->parameters['id'], $request['account_ids']);
}
/**
if (!Session::getLocalUser()) {
if ($interactive) {
DI::sysmsg()->addNotice(DI::l10n()->t('Please login to continue.'));
- Session::set('return_path', DI::args()->getQueryString());
+ DI::session()->set('return_path', DI::args()->getQueryString());
DI::baseUrl()->redirect('login');
} else {
throw new HTTPException\UnauthorizedException(DI::l10n()->t('Please login to continue.'));
class Community extends BaseModule
{
/**
- * @name CP
- *
* Type of the community page
* @{
*/
use Friendica\BaseModule;
use Friendica\Core\Hook;
use Friendica\Core\Renderer;
+use Friendica\Core\Session;
use Friendica\Database\DBA;
use Friendica\DI;
use Friendica\Model\Notification;
{
protected function content(array $request = []): string
{
- if ((Session::getLocalUser()) && ($this->parameters['action'] ?? '') === 'view') {
+ if (Session::getLocalUser() && ($this->parameters['action'] ?? '') === 'view') {
// A logged in user views a profile of a user
$nickname = DI::app()->getLoggedInUserNickname();
} elseif (empty($this->parameters['action'])) {