Skip to content

Conversation

yguedidi
Copy link
Contributor

@yguedidi yguedidi commented Mar 23, 2023

/**
* @param array<string, mixed> $config
*
* @return string|string[]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When does it return a string and when does it return an array?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Returning a string is treated the same than returning an array containing a single item by the Symfony code calling this factory. It allows to simplify the most common case which only needs to create a single authenticator.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ondrejmirtes is there anything else I can do?

@ondrejmirtes ondrejmirtes merged commit 1da7bf4 into phpstan:1.2.x Apr 5, 2023
@ondrejmirtes
Copy link
Member

Thank you!

1 similar comment
@ondrejmirtes
Copy link
Member

Thank you!

@yguedidi yguedidi deleted the security-factory branch April 5, 2023 12:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants