for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Waca\Router;
use Waca\Pages\Request\PageConfirmEmail;
use Waca\Pages\Request\PageEmailConfirmationRequired;
use Waca\Pages\Request\PageRequestAccount;
use Waca\Pages\Request\PageRequestSubmitted;
class PublicRequestRouter extends RequestRouter
{
/**
* Gets the route map to be used by this request router.
*
* @return array
array<string,array<string,array>>
This check looks for the generic type array as a return type and suggests a more specific type. This type is inferred from the actual code.
array
*/
protected function getRouteMap()
return array(
// Page showing a message stating the request has been submitted to our internal queues
'requestSubmitted' =>
array(
'class' => PageRequestSubmitted::class,
'actions' => array(),
),
// Page showing a message stating that email confirmation is required to continue
'emailConfirmationRequired' =>
'class' => PageEmailConfirmationRequired::class,
// Action page which handles email confirmation
'confirmEmail' =>
'class' => PageConfirmEmail::class,
);
}
* Gets the default route if no explicit route is requested.
* @return callable
string[]
protected function getDefaultRoute()
return array(PageRequestAccount::class, 'main');
This check looks for the generic type
arrayas a return type and suggests a more specific type. This type is inferred from the actual code.