Skip to content

Commit

Permalink
Fixing strict return type
Browse files Browse the repository at this point in the history
Fixing: Method HiFolks\DataType\Block::toArray() return type has no value type specified in iterable type array.
  • Loading branch information
roberto-butti committed Jun 16, 2024
1 parent e833a04 commit 7f8b42c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/Block.php
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,10 @@ public function orderBy(string|int $field, string $order = 'desc'): self
return self::make($array);
}

/**
* Returns the native array
* @return array<int|string, mixed>
*/
public function toArray(): array
{
return $this->data;
Expand Down
2 changes: 1 addition & 1 deletion tests/Unit/BlockGetTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ function () use ($fruitsArray) {



}
},
);


Expand Down

0 comments on commit 7f8b42c

Please sign in to comment.