mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-09 02:06:32 +02:00
[ticket/15351] Makes confirm_works in a router context (app.php)
PHPBB3-15351
This commit is contained in:
@@ -496,4 +496,17 @@ class path_helper
|
||||
|
||||
return $page;
|
||||
}
|
||||
|
||||
/**
|
||||
* Tells if the router is currently in use (if the current page is a route or not)
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function is_router_used()
|
||||
{
|
||||
// Script name URI (e.g. phpBB/app.php)
|
||||
$script_name = $this->symfony_request->getScriptName();
|
||||
|
||||
return basename($script_name) === 'app.' . $this->php_ext;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user