mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-13 05:24:03 +00:00
Finish path identification - configurability & exception handling
This commit is contained in:
parent
cb2bd018aa
commit
494d274798
4 changed files with 83 additions and 5 deletions
16
src/Exceptions/RouteIsMissingTenantParameterException.php
Normal file
16
src/Exceptions/RouteIsMissingTenantParameterException.php
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
<?php
|
||||
|
||||
namespace Stancl\Tenancy\Exceptions;
|
||||
|
||||
use Exception;
|
||||
use Stancl\Tenancy\Resolvers\PathTenantResolver;
|
||||
|
||||
class RouteIsMissingTenantParameterException extends Exception
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
$parameter = PathTenantResolver::$tenantParameterName;
|
||||
|
||||
parent::__construct("The route's first argument is not the tenant id (configured paramter name: $parameter).");
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue