Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix CZ Person birthNumber docblock return type #437

Merged
merged 3 commits into from Jan 27, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 0 additions & 10 deletions phpstan-baseline.neon
Expand Up @@ -829,16 +829,6 @@ parameters:
count: 2
path: src/Faker/Provider/cs_CZ/DateTime.php

-
message: "#^Method Faker\\\\Provider\\\\cs_CZ\\\\Person\\:\\:birthNumber\\(\\) should return Faker\\\\Provider\\\\cs_CZ\\\\czech but returns string\\.$#"
count: 1
path: src/Faker/Provider/cs_CZ/Person.php

-
message: "#^Return typehint of method Faker\\\\Provider\\\\cs_CZ\\\\Person\\:\\:birthNumber\\(\\) has invalid type Faker\\\\Provider\\\\cs_CZ\\\\czech\\.$#"
count: 1
path: src/Faker/Provider/cs_CZ/Person.php

-
message: "#^Static call to instance method Faker\\\\Provider\\\\cs_CZ\\\\Person\\:\\:birthNumber\\(\\)\\.$#"
count: 2
Expand Down
9 changes: 0 additions & 9 deletions psalm.baseline.xml
Expand Up @@ -181,19 +181,10 @@
</UndefinedPropertyFetch>
</file>
<file src="src/Faker/Provider/cs_CZ/Person.php">
<InvalidReturnStatement occurrences="1">
<code>$birthNumber</code>
</InvalidReturnStatement>
<InvalidReturnType occurrences="1">
<code>czech</code>
</InvalidReturnType>
<NonStaticSelfCall occurrences="2">
<code>static::birthNumber(static::GENDER_FEMALE)</code>
<code>static::birthNumber(static::GENDER_MALE)</code>
</NonStaticSelfCall>
<UndefinedDocblockClass occurrences="1">
<code>czech</code>
</UndefinedDocblockClass>
</file>
<file src="src/Faker/Provider/en_SG/Person.php">
<InvalidArrayOffset occurrences="1">
Expand Down
2 changes: 1 addition & 1 deletion src/Faker/Provider/cs_CZ/Person.php
Expand Up @@ -430,7 +430,7 @@ class Person extends \Faker\Provider\Person
* @param int $minAge minimal age of "generated person" in years
* @param int $maxAge maximal age of "generated person" in years
*
* @return czech birth number
* @return string czech birth number
*/
public function birthNumber($gender = null, $minAge = 0, $maxAge = 100, $slashProbability = 50)
{
Expand Down