Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
Signed-off-by: Mior Muhammad Zaki <crynobone@gmail.com>
  • Loading branch information
crynobone committed Dec 10, 2021
1 parent 94cbf67 commit 3ecddf5
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 8 deletions.
2 changes: 1 addition & 1 deletion phpstan.neon.dist
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ parameters:
- src

# The level 8 is the highest level
level: 8
level: 9

ignoreErrors:
- '#Unsafe usage of new static#'
Expand Down
8 changes: 2 additions & 6 deletions src/Column.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,7 @@ public function getOriginalValue()
*/
public function getValue(): string
{
if (\is_string($this->name)) {
return $this->name;
}

return $this->name->getValue();
return (string) $this->name;
}

/**
Expand All @@ -96,7 +92,7 @@ public function validate(): bool

/**
* Get if column is acceptable for filter.
*
*
* @param array<int, string> $only
* @param array<int, string> $except
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Filters/PrimaryKeySearch.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public function apply($query, array $keywords, string $likeOperator, ?string $wh
/**
* Determine if can search primary key.
*
* @param string|int $search
* @param mixed $search
*/
protected function canSearchPrimaryKey(Model $model, $search): bool
{
Expand Down

0 comments on commit 3ecddf5

Please sign in to comment.