Skip to content

Commit 7954973

Browse files
committed
Make Attribute classes readonly
1 parent 37c0b0f commit 7954973

6 files changed

Lines changed: 6 additions & 6 deletions

File tree

Attributes/AccessControl.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
use Attribute;
2424

2525
#[Attribute(Attribute::TARGET_METHOD)]
26-
class AccessControl
26+
readonly class AccessControl
2727
{
2828
/**
2929
* AccessControl constructor.

Attributes/Action.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
use Attribute;
2424

2525
#[Attribute(Attribute::TARGET_METHOD)]
26-
class Action
26+
readonly class Action
2727
{
2828
public function __construct(public string $usage = '', public string $description = '')
2929
{

Attributes/JsonItem.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
use Feast\Date;
2525

2626
#[Attribute(Attribute::TARGET_PROPERTY)]
27-
class JsonItem
27+
readonly class JsonItem
2828
{
2929
/**
3030
* JsonItem constructor.

Attributes/JsonParam.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
use Attribute;
2424

2525
#[Attribute(Attribute::TARGET_PARAMETER)]
26-
class JsonParam
26+
readonly class JsonParam
2727
{
2828
public function __construct(public string $key = '')
2929
{

Attributes/Param.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
use Feast\Terminal;
2626

2727
#[Attribute(Attribute::TARGET_METHOD | Attribute::IS_REPEATABLE)]
28-
class Param
28+
readonly class Param
2929
{
3030
public function __construct(
3131
public string $type = '',

Attributes/Path.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
use Feast\Enums\RequestMethod;
2525

2626
#[Attribute(Attribute::TARGET_METHOD)]
27-
class Path
27+
readonly class Path
2828
{
2929
final public const METHOD_GET = 1;
3030
final public const METHOD_POST = 2;

0 commit comments

Comments
 (0)