Friendica Communications Platform (please note that this is a clone of the repository at github, issues are handled there) https://friendi.ca
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
friendica/src/Module/Logout.php

30 lines
529 B

<?php
/**
* @file src/Module/Logout.php
*/
namespace Friendica\Module;
use Friendica\BaseModule;
use Friendica\Core\Authentication;
use Friendica\Core\Hook;
use Friendica\Core\L10n;
/**
* Logout module
*
* @author Hypolite Petovan <hypolite@mrpetovan.com>
*/
class Logout extends BaseModule
{
/**
* @brief Process logout requests
*/
public static function init()
{
Hook::callAll("logging_out");
Authentication::deleteSession();
info(L10n::t('Logged out.') . EOL);
self::getApp()->internalRedirect();
}
}