mirror of
https://github.com/MCV-Software/TWBlue.git
synced 2024-11-22 19:28:09 -06:00
Filters will work in main buffers too. #102
This commit is contained in:
parent
5f7f176892
commit
e303d914fe
@ -27,21 +27,23 @@ class streamer(TwythonStreamer):
|
|||||||
|
|
||||||
def put_data(self, place, data):
|
def put_data(self, place, data):
|
||||||
if self.session.db.has_key(place):
|
if self.session.db.has_key(place):
|
||||||
if utils.find_item(data["id"], self.session.db[place]) != None and utils.is_allowed(data, self.session.settings, place):
|
if utils.find_item(data["id"], self.session.db[place]) != None:
|
||||||
log.error("duplicated tweet. Ignoring it...")
|
log.error("duplicated tweet. Ignoring it...")
|
||||||
return False
|
return False
|
||||||
# try:
|
# try:
|
||||||
data_ = self.session.check_quoted_status(data)
|
if utils.is_allowed(data, self.session.settings, place):
|
||||||
data_ = self.session.check_long_tweet(data_)
|
data_ = self.session.check_quoted_status(data)
|
||||||
data = data_
|
data_ = self.session.check_long_tweet(data_)
|
||||||
|
data = data_
|
||||||
# except:
|
# except:
|
||||||
# pass
|
# pass
|
||||||
if self.session.settings["general"]["reverse_timelines"] == False:
|
if self.session.settings["general"]["reverse_timelines"] == False:
|
||||||
self.session.db[place].append(data)
|
self.session.db[place].append(data)
|
||||||
else:
|
else:
|
||||||
self.session.db[place].insert(0, data)
|
self.session.db[place].insert(0, data)
|
||||||
utils.is_audio(data)
|
utils.is_audio(data)
|
||||||
return True
|
return True
|
||||||
|
return False
|
||||||
|
|
||||||
def block_user(self, data):
|
def block_user(self, data):
|
||||||
id = data["target"]["id"]
|
id = data["target"]["id"]
|
||||||
|
Loading…
Reference in New Issue
Block a user