19 lines
483 B
PHP
Executable File
19 lines
483 B
PHP
Executable File
<?php
|
|
|
|
namespace Modules\Stylist\Theme\Exceptions;
|
|
|
|
use RuntimeException;
|
|
|
|
final class InvalidThemeManifestException extends RuntimeException
|
|
{
|
|
/** @param array<int, string> $errors */
|
|
public static function forPath(string $path, array $errors): self
|
|
{
|
|
return new self(sprintf(
|
|
'Invalid theme manifest at [%s]: %s',
|
|
rtrim($path, DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR.'theme.json',
|
|
implode(' ', $errors),
|
|
));
|
|
}
|
|
}
|