Skip to content

Various corner case fixes for database_api

Andrzej Lisak requested to merge database_api_corner_fixes into develop

[Fix] find_votes now limits response to 1000 votes like in fat node; find_votes SQL routine now comes with limit (but limit is 1000 everywhere which might potentially influence vote listing in various API calls, on the other hand it might be seen as safety measure; in the end we should only give number of votes in all API responses with posts, leaving it to caller to ask for votes explicitly)

[Fix] valid_number now properly treats 0 according to lbound:ubound instead of always as an error (influences border case of limit param and specific value of score param)

[Change] list_comments/list_votes now have default value (1000) on limit parameter (which became optional)

[Fix] added checks on find_votes: comment param must be a list; no longer fails on elements that are not (at least) pairs of strings or on (effectively) empty list

Merge request reports

Loading