check if workaroundTokens are None before trying to split them
* the default config has them set to null, so we should check first
This commit is contained in:
parent
0b43a3e05a
commit
0e6748d86a
@ -177,7 +177,12 @@ def getTweetData(twitter_url,include_txt="false",include_rtf="false"):
|
|||||||
rawTweetData = None
|
rawTweetData = None
|
||||||
if rawTweetData is None:
|
if rawTweetData is None:
|
||||||
try:
|
try:
|
||||||
rawTweetData = twExtract.extractStatus(twitter_url,workaroundTokens=config['config']['workaroundTokens'].split(','))
|
if config['config']['workaroundTokens'] is not None:
|
||||||
|
workaroundTokens = config['config']['workaroundTokens'].split(",")
|
||||||
|
else:
|
||||||
|
workaroundTokens = None
|
||||||
|
|
||||||
|
rawTweetData = twExtract.extractStatus(twitter_url,workaroundTokens=workaroundTokens)
|
||||||
except:
|
except:
|
||||||
rawTweetData = None
|
rawTweetData = None
|
||||||
if rawTweetData == None or 'error' in rawTweetData:
|
if rawTweetData == None or 'error' in rawTweetData:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user