mirror of
https://github.com/shlinkio/shlink.git
synced 2026-02-28 04:03:12 +08:00
22 lines
496 B
PHP
22 lines
496 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace Shlinkio\Shlink\Rest\Exception;
|
|
|
|
use function sprintf;
|
|
|
|
class ApiKeyNotFoundException extends RuntimeException implements ExceptionInterface
|
|
{
|
|
public static function forName(string $name): self
|
|
{
|
|
return new self(sprintf('API key with name "%s" not found', $name));
|
|
}
|
|
|
|
/** @deprecated */
|
|
public static function forKey(string $key): self
|
|
{
|
|
return new self(sprintf('API key with key "%s" not found', $key));
|
|
}
|
|
}
|