Skip to content

Commit

Permalink
Ignore static calls in Exception
Browse files Browse the repository at this point in the history
  • Loading branch information
stefanzweifel committed Apr 1, 2024
1 parent c60e535 commit ba206f4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion phpstan.neon
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
parameters:
level: 6
level: 5
paths:
- src
- tests
3 changes: 3 additions & 0 deletions src/Exceptions/CantonException.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,19 @@ class CantonException extends Exception
{
public static function notFoundForAbbreviation(string $abbreviation): self
{
/** @phpstan-ignore-next-line */
return new static("Couldn't find Canton for given abbreviation: {$abbreviation}");
}

public static function notFoundForName(string $name): self
{
/** @phpstan-ignore-next-line */
return new static("Couldn't find Canton for given name: {$name}");
}

public static function notFoundForZipcode(int $zipcode): self
{
/** @phpstan-ignore-next-line */
return new static("Couldn't find Canton for given zipcode: {$zipcode}");
}
}

0 comments on commit ba206f4

Please sign in to comment.