Skip to content

Fix Link header for Tree API requests

Vasilii Iakliushin requested to merge 468798_fix_link_for_the_last_page into master

What does this MR do and why?

Contributes to #468798 (closed)

Problem

When user requests exact number of available elements, then the app returns a Link header with a link to a non-existing page.

Solution

Verify the next cursor value and don't respond with Link header when the next cursor is missing.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After
Screenshot_2024-07-01_at_11.39.34 Screenshot_2024-07-01_at_11.39.45

How to set up and validate locally

Steps to reproduce

Edited by Vasilii Iakliushin

Merge request reports

Loading