chore: flatten namespace
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace App\Model;
|
||||
|
||||
class NewsletterConfirmationResult
|
||||
{
|
||||
public const STATUS_CONFIRMED = 'confirmed';
|
||||
public const STATUS_INVALID = 'invalid';
|
||||
public const STATUS_EXPIRED = 'expired';
|
||||
public const STATUS_ALREADY_USED = 'already_used';
|
||||
|
||||
public function __construct(
|
||||
public readonly string $status,
|
||||
public readonly ?string $email = null,
|
||||
) {
|
||||
}
|
||||
|
||||
public function isSuccess(): bool
|
||||
{
|
||||
return self::STATUS_CONFIRMED === $this->status;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user