mirror of
https://gitlab.com/jeancf/twoot.git
synced 2024-11-27 14:01:13 +00:00
Remove unnecessary repeat creation of Mastodon object
This commit is contained in:
parent
38e505ad6e
commit
faedf27a37
8
twoot.py
8
twoot.py
|
@ -981,10 +981,10 @@ def main(argv):
|
|||
# Post toot
|
||||
toot = {}
|
||||
try:
|
||||
mastodon = Mastodon(
|
||||
access_token=TOML['config']['mastodon_user'] + '.secret',
|
||||
api_base_url='https://' + TOML['config']['mastodon_instance']
|
||||
)
|
||||
# mastodon = Mastodon(
|
||||
# access_token=TOML['config']['mastodon_user'] + '.secret',
|
||||
# api_base_url='https://' + TOML['config']['mastodon_instance']
|
||||
# )
|
||||
|
||||
if len(media_ids) == 0:
|
||||
toot = mastodon.status_post(tweet['tweet_text'])
|
||||
|
|
Loading…
Reference in New Issue
Block a user