mirror of
https://github.com/RSS-Bridge/rss-bridge.git
synced 2025-08-16 05:24:08 +02:00
bridges: Fix default return values and function scopes
getURI and getName should fall back to parent::getURI or parent::getName respectively if it cannot build propper return values. Functions defined by bridges should be made private to prevent confusion with inherited functions
This commit is contained in:
@@ -103,6 +103,7 @@ EOD;
|
||||
case 'From search':
|
||||
$uri = self::URI . 'search/?q=' . urlencode($this->getInput('q'));
|
||||
break;
|
||||
default: return parent::getURI();
|
||||
}
|
||||
return $uri;
|
||||
}
|
||||
@@ -115,6 +116,7 @@ EOD;
|
||||
case 'From search':
|
||||
$specific = $this->getInput('q');
|
||||
break;
|
||||
default: return parent::getName();
|
||||
}
|
||||
return $specific . ' - ' . self::NAME;
|
||||
}
|
||||
|
Reference in New Issue
Block a user