aboutsummaryrefslogtreecommitdiff
path: root/app/Controllers/feedController.php
diff options
context:
space:
mode:
authorGravatar Django Janny <django.janny@gmail.com> 2018-02-02 13:59:48 +0100
committerGravatar Django Janny <django.janny@gmail.com> 2018-02-02 13:59:48 +0100
commit5faa7aaf66aa2e762922b293cb9b7293a5003a7d (patch)
tree7eeaf759dd95156d6332ac55f45bb768619a8fbc /app/Controllers/feedController.php
parentfb541b1bacb198be7ccac9341415facb91b7dc81 (diff)
Trim spaces from user given url
Diffstat (limited to 'app/Controllers/feedController.php')
-rwxr-xr-xapp/Controllers/feedController.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/app/Controllers/feedController.php b/app/Controllers/feedController.php
index 884172112..985b943d2 100755
--- a/app/Controllers/feedController.php
+++ b/app/Controllers/feedController.php
@@ -39,12 +39,14 @@ class FreshRSS_feed_Controller extends Minz_ActionController {
* @throws FreshRSS_Feed_Exception
* @throws Minz_FileNotExistException
*/
- public static function addFeed($url, $title = '', $cat_id = 0, $new_cat_name = '', $http_auth = '') {
+ public static function addFeed($param_url, $title = '', $cat_id = 0, $new_cat_name = '', $http_auth = '') {
FreshRSS_UserDAO::touch();
@set_time_limit(300);
$catDAO = new FreshRSS_CategoryDAO();
+ $url = trim($param_url);
+
$cat = null;
if ($new_cat_name != '') {
$new_cat_id = $catDAO->addCategory(array('name' => $new_cat_name));