From 96ac72bc12ab0f5a79c48b2542d4a20088d87f0a Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Sun, 12 Jul 2015 13:18:03 +0300 Subject: [PATCH] api: getHeadlines: cast feed_it to int if needed --- classes/api.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/classes/api.php b/classes/api.php index cbb4720c..2691625c 100644 --- a/classes/api.php +++ b/classes/api.php @@ -184,6 +184,8 @@ class API extends Handler { $feed_id = $this->dbh->escape_string($_REQUEST["feed_id"]); if ($feed_id != "") { + if (is_numeric($feed_id)) $feed_id = (int) $feed_id; + $limit = (int)$this->dbh->escape_string($_REQUEST["limit"]); if (!$limit || $limit >= 200) $limit = 200; -- 2.39.5