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

#[derive(WpDerivedRequest)]'s contextual_get should return error for non SparseFoo types #152

Open
oguzkocer opened this issue Jun 20, 2024 · 0 comments
Assignees
Labels
Milestone

Comments

@oguzkocer
Copy link
Contributor

contextual_get works the same way as #[derive(WpContextual)] does, as it replaces SparseFoo with FooWithEditContext, FooWithEmbedContext & FooWithViewContext. To ensure that we always work with correct output types, we should return a compiler error if the output type of WpDerivedRequest doesn't have the Sparse prefix if the contextual_get attribute is used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant