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

[Microsoft.AspNet.OData v7.7.3] Request.ODataProperties().NextLink is always null #2826

Open
amanswaika opened this issue Dec 14, 2023 · 0 comments
Assignees

Comments

@amanswaika
Copy link

amanswaika commented Dec 14, 2023

Short summary (3-5 sentences) describing the issue.

We recently upgraded to Microsoft.AspNet.OData v7.7.3 from v7.1.0.
We have a scenario where we manually update a part of @odata.nextLink before returning it.

We fetch the nextLink using Request.ODataProperties().NextLink and make the neccesarry modifications. However, since the upgrade - Request.ODataProperties().NextLink is always returning null even though the final Api response returns the nextLink (just not in our desired format).

Assemblies affected

Microsoft.AspNet.OData v7.7.3

Code sample -

var data = queryOptions.ApplyTo(queryable, odataQuerySettings, this.IgnoredQueryOptions);

var nextLink = queryOptions.Request.ODataProperties().NextLink;

// The above is always null even though all the queryOptions have applied correctly

But the Api response has the next link present -

image

@habbes habbes self-assigned this Dec 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants