diff --git a/bridges/RedditBridge.php b/bridges/RedditBridge.php index 1dbd8d91c6f..b83871a96a1 100644 --- a/bridges/RedditBridge.php +++ b/bridges/RedditBridge.php @@ -8,6 +8,15 @@ class RedditBridge extends BridgeAbstract { const DESCRIPTION = 'Return hot submissions from Reddit'; const PARAMETERS = array( + 'global' => array( + 'score' => array( + 'name' => 'Minimal score', + 'required' => false, + 'type' => 'number', + 'exampleValue' => 100, + 'title' => 'Filter out posts with lower score' + ) + ), 'single' => array( 'r' => array( 'name' => 'SubReddit', @@ -86,6 +95,10 @@ public function collectData() { $data = $post->data; + if ($data->score < $this->getInput('score')) { + continue; + } + $item = array(); $item['author'] = $data->author; $item['uid'] = $data->id;