mirror of
https://github.com/MCV-Software/TWBlue.git
synced 2025-04-05 03:12:29 -04:00
A fw bugfixes
This commit is contained in:
parent
ce1f8b2cc3
commit
bdb9de863f
@ -5,7 +5,7 @@ if snapshot == False:
|
|||||||
version = "0.80"
|
version = "0.80"
|
||||||
update_url = 'http://twblue.es/updates/twblue_ngen.json'
|
update_url = 'http://twblue.es/updates/twblue_ngen.json'
|
||||||
else:
|
else:
|
||||||
version = "10.8"
|
version = "10.9"
|
||||||
update_url = 'http://twblue.es/updates/snapshots_ngen.json'
|
update_url = 'http://twblue.es/updates/snapshots_ngen.json'
|
||||||
author = u"Manuel Cortéz, Bill Dengler"
|
author = u"Manuel Cortéz, Bill Dengler"
|
||||||
authorEmail = "manuel@manuelcortez.net"
|
authorEmail = "manuel@manuelcortez.net"
|
||||||
|
@ -30,5 +30,6 @@ def is_long(tweet):
|
|||||||
|
|
||||||
def clear_url(tweet):
|
def clear_url(tweet):
|
||||||
urls = utils.find_urls_in_text(tweet["text"])
|
urls = utils.find_urls_in_text(tweet["text"])
|
||||||
tweet["message"] = tweet["message"].replace(urls[-1]+".", "")
|
try: tweet["message"] = tweet["message"].replace(urls[-1]+".", "")
|
||||||
|
except IndexError: pass
|
||||||
return tweet
|
return tweet
|
@ -432,7 +432,8 @@ class Session(object):
|
|||||||
except IndexError: pass
|
except IndexError: pass
|
||||||
l = tweets.is_long(quoted_tweet)
|
l = tweets.is_long(quoted_tweet)
|
||||||
id = tweets.get_id(l)
|
id = tweets.get_id(l)
|
||||||
original_tweet = self.twitter.twitter.show_status(id=id)
|
try: original_tweet = self.twitter.twitter.show_status(id=id)
|
||||||
|
except: return quoted_tweet
|
||||||
urls = utils.find_urls_in_text(original_tweet["text"])
|
urls = utils.find_urls_in_text(original_tweet["text"])
|
||||||
for url in range(0, len(urls)):
|
for url in range(0, len(urls)):
|
||||||
try: original_tweet["text"] = original_tweet["text"].replace(urls[url], original_tweet["entities"]["urls"][url]["expanded_url"])
|
try: original_tweet["text"] = original_tweet["text"].replace(urls[url], original_tweet["entities"]["urls"][url]["expanded_url"])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user