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: pipe functions in projections #264

Merged
merged 1 commit into from
Nov 28, 2024

Conversation

okj579
Copy link
Contributor

@okj579 okj579 commented Nov 19, 2024

This fixes pipe functions inside object projections, like the query below:

const input = `*[_type == "user"] {
    name,
    refs[]-> | order(name)
}`;
const dataset = [
    {_id: '1', _type: 'user', name: 'Michael', refs: [{_ref:'1'}, {_ref:'2'}]},
    {_id: '2', _type: 'company', name: 'Bluth Company'},
];

@sgulseth sgulseth merged commit 40e6c25 into sanity-io:main Nov 28, 2024
8 checks passed
@sgulseth
Copy link
Member

Thanks! Sorry it took so much time, wanted to make sure we had test coverage for this case

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.

2 participants