mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-13 03:54:02 +00:00
Remove obsolete files, restructure
This commit is contained in:
parent
fbe43fbb04
commit
4f8d892481
20 changed files with 19 additions and 83 deletions
|
|
@ -1,15 +0,0 @@
|
|||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Stancl\Tenancy\Exceptions;
|
||||
|
||||
use Exception;
|
||||
|
||||
class NotImplementedException extends Exception
|
||||
{
|
||||
public function __construct($class, $method, $extra)
|
||||
{
|
||||
parent::__construct("The $class class does not implement the $method method. $extra");
|
||||
}
|
||||
}
|
||||
|
|
@ -1,15 +0,0 @@
|
|||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Stancl\Tenancy\Exceptions;
|
||||
|
||||
use Exception;
|
||||
|
||||
class TenantDoesNotExistException extends Exception
|
||||
{
|
||||
public function __construct(string $id, string $key = 'id')
|
||||
{
|
||||
$this->message = "Tenant with this $key does not exist: $id";
|
||||
}
|
||||
}
|
||||
|
|
@ -1,9 +0,0 @@
|
|||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Stancl\Tenancy\Exceptions;
|
||||
|
||||
class TenantStorageException extends \Exception
|
||||
{
|
||||
}
|
||||
|
|
@ -1,25 +0,0 @@
|
|||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Stancl\Tenancy\Exceptions;
|
||||
|
||||
use Stancl\Tenancy\Contracts\TenantCannotBeCreatedException;
|
||||
|
||||
class TenantWithThisIdAlreadyExistsException extends TenantCannotBeCreatedException
|
||||
{
|
||||
/** @var string */
|
||||
protected $id;
|
||||
|
||||
public function reason(): string
|
||||
{
|
||||
return "Tenant with id {$this->id} already exists.";
|
||||
}
|
||||
|
||||
public function __construct(string $id)
|
||||
{
|
||||
parent::__construct();
|
||||
|
||||
$this->id = $id;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue