mirror of
https://gitlab.com/oloturia/damastodon.git
synced 2025-01-06 21:47:15 +01:00
fixed login.py, now it can be called from another dir
This commit is contained in:
parent
af52f887fd
commit
0093618940
1 changed files with 5 additions and 1 deletions
6
login.py
6
login.py
|
@ -1,8 +1,12 @@
|
|||
from mastodon import Mastodon
|
||||
import os
|
||||
|
||||
fileDir = os.path.dirname(os.path.abspath(__file__))
|
||||
fileDir = fileDir +"/"
|
||||
|
||||
def login(url):
|
||||
mastodon = Mastodon(
|
||||
access_token = "DAMA.SECRET",
|
||||
access_token = fileDir+"DAMA.SECRET",
|
||||
api_base_url = url
|
||||
)
|
||||
return mastodon
|
||||
|
|
Loading…
Reference in a new issue