lib/weeter/twitter/tweet_consumer.rb in weeter-0.9.1 vs lib/weeter/twitter/tweet_consumer.rb in weeter-0.9.2

- old
+ new

@@ -44,24 +44,25 @@ @stream.stop connect(filter_params) end protected - + def clean_filter_params(p) return {} if p.nil? cleaned_params = {} cleaned_params['follow'] = p['follow'] if (p['follow'] || []).any? + cleaned_params['follow'] = cleaned_params['follow'].map(&:to_i) cleaned_params['track'] = p['track'] if (p['track'] || []).any? cleaned_params end - + def ignore_tweet(tweet_item) id = tweet_item['id_str'] text = tweet_item['text'] user_id = tweet_item['user']['id_str'] Weeter.logger.info("Ignoring tweet #{id} from user #{user_id}: #{text}") end end end -end \ No newline at end of file +end