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

Breaking change between 0.19.2 and 0.20.0 #556

Open
vlowe85 opened this issue Jun 13, 2022 · 1 comment
Open

Breaking change between 0.19.2 and 0.20.0 #556

vlowe85 opened this issue Jun 13, 2022 · 1 comment

Comments

@vlowe85
Copy link

vlowe85 commented Jun 13, 2022

Is there an upgrade guide for breaking changes between versions?

@vlowe85
Copy link
Author

vlowe85 commented Jun 13, 2022

See this commit 5bf32b5 (Added PHP 7.4 types)

protected function item($data, $transformer, ?string $resourceKey = null): Item
item still works ok as not enforcing callable, primitive is broken..
protected function primitive($data, ?callable $transformer = null, ?string $resourceKey = null): Primitive

when used like

    public function includeFavorites(User $user)
    {
        return $this->primitive($user, new FavoritesTransformer);
    }

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