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

Phalcon\Mvc\Model::findFirst() Incorrect annotation return type #2

Open
s-ohnishi opened this issue May 24, 2020 · 0 comments
Open

Comments

@s-ohnishi
Copy link

     * @return bool|\Phalcon\Mvc\ModelInterface
     */
    public static function findFirst($parameters = null)
    {
    }

I think it should be this.

     * @return null|\Phalcon\Mvc\ModelInterface
     */
    public static function findFirst($parameters = null)
    {
    }

because

public static function findFirst(
    mixed $parameters = null
): ModelInterface | null

and

NOTE: findFirst() no longer returns false if records were not found.

https://docs.phalcon.io/4.0/en/db-models

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

No branches or pull requests

1 participant