-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
WebAPI: Do not wrap result if offset is invalid #22174
base: master
Are you sure you want to change the base?
WebAPI: Do not wrap result if offset is invalid #22174
Conversation
…of-bound. So we dont need the condition.
Could you summarize how it will behave after applying this patch? Note that in the description of the PR, it is better to indicate how it will behave after merging it than just the problem itself (the description of the problem is generally redundant if there is a corresponding Issue to which it refers). |
Yeah sure. I will write down a few example cases below, but the main gist is that if a (positive) If (negative) So ... lets say we have 5 torrents.
Hope this explanation is good enough . |
IIRC, now it doesn't match the following part of OP:
|
|
I just want to say about inconsistency between described expectations and end result. Either one or another should be adjusted. P.S. I would just remove Description section from OP or replace it with description of how it is supposed to behave after merging this PR (as I suggested above). |
Closes #22158.
Description
On requests to
/api/v2/torrents/info
endpoint with anoffset
larger than the number of torrents, theoffset
defaults to0
and returns results when its expected to return an error informing that this offset is out of range.