1
0
Fork 0

Add profile page aliases to routes

This commit is contained in:
Hypolite Petovan 2020-09-09 00:13:11 -04:00
parent 043e04f484
commit e23f3a645a

View file

@ -30,6 +30,14 @@
use Friendica\App\Router as R; use Friendica\App\Router as R;
use Friendica\Module; use Friendica\Module;
$profileRoutes = [
'' => [Module\Profile\Index::class, [R::GET]],
'/profile' => [Module\Profile\Profile::class, [R::GET]],
'/contacts/common' => [Module\Profile\Common::class, [R::GET]],
'/contacts[/{type}]' => [Module\Profile\Contacts::class, [R::GET]],
'/status[/{category}[/{date1}[/{date2}]]]' => [Module\Profile\Status::class, [R::GET]],
];
return [ return [
'/' => [Module\Home::class, [R::GET]], '/' => [Module\Home::class, [R::GET]],
@ -250,13 +258,9 @@ return [
'/pretheme' => [Module\ThemeDetails::class, [R::GET]], '/pretheme' => [Module\ThemeDetails::class, [R::GET]],
'/probe' => [Module\Debug\Probe::class, [R::GET]], '/probe' => [Module\Debug\Probe::class, [R::GET]],
'/profile' => [ '/profile/{nickname}' => $profileRoutes,
'/{nickname}' => [Module\Profile\Index::class, [R::GET]], '/u/{nickname}' => $profileRoutes,
'/{nickname}/profile' => [Module\Profile\Profile::class, [R::GET]], '/~{nickname}' => $profileRoutes,
'/{nickname}/contacts/common' => [Module\Profile\Common::class, [R::GET]],
'/{nickname}/contacts[/{type}]' => [Module\Profile\Contacts::class, [R::GET]],
'/{nickname}/status[/{category}[/{date1}[/{date2}]]]' => [Module\Profile\Status::class, [R::GET]],
],
'/proxy' => [ '/proxy' => [
'[/]' => [Module\Proxy::class, [R::GET]], '[/]' => [Module\Proxy::class, [R::GET]],