tt-rss-newsplus-plugin icon indicating copy to clipboard operation
tt-rss-newsplus-plugin copied to clipboard

Limit defaults to unlimited rather than 20

Open JKingweb opened this issue 7 years ago • 0 comments

Line 47 reads as follows:

$limit = (int) db_escape_string($_REQUEST["limit"]);

This results in null (as well as various invalid input) being passed along as zero (no limit). The following lines would have the desired result:

$limit = db_escape_string($_REQUEST["limit"]);
$limit = (int) (is_numeric($limit) ? $limit : 20);

Alternatively (and I think this is the better option), this could instead be considered a documentation bug, and the default should officially be unlimited, with the documentation as well as line 64 adjusted accordingly.

JKingweb avatar Nov 17 '17 18:11 JKingweb