mirror of
https://github.com/solidtime-io/solidtime.git
synced 2026-10-09 06:13:17 +01:00
Fix Scramble API docs warnings
Remove redundant @var annotations from API resources and defer the user access in the email unique rule of UserUpdateRequest, so rules() can be evaluated by Scramble without route model binding. Add a test that fails on any Scramble diagnostic and tests for the email unique rule.
This commit is contained in:
committed by
Constantin Graf
parent
4a2f78931a
commit
f01a4111b6
@@ -21,15 +21,15 @@ class ClientResource extends BaseResource
|
||||
public function toArray(Request $request): array
|
||||
{
|
||||
return [
|
||||
/** @var string $id ID */
|
||||
/** ID */
|
||||
'id' => $this->resource->id,
|
||||
/** @var string $name Name */
|
||||
/** Name */
|
||||
'name' => $this->resource->name,
|
||||
/** @var bool $is_archived Whether the client is archived */
|
||||
/** Whether the client is archived */
|
||||
'is_archived' => $this->resource->is_archived,
|
||||
/** @var string $created_at When the tag was created */
|
||||
/** When the tag was created */
|
||||
'created_at' => $this->formatDateTime($this->resource->created_at),
|
||||
/** @var string $updated_at When the tag was last updated */
|
||||
/** When the tag was last updated */
|
||||
'updated_at' => $this->formatDateTime($this->resource->updated_at),
|
||||
];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user