Adding in .env loading of credentials
This commit is contained in:
+2
-2
@@ -7,8 +7,8 @@ from dotenv import load_dotenv
|
|||||||
|
|
||||||
load_dotenv()
|
load_dotenv()
|
||||||
|
|
||||||
consumer_key = os.getenv('CKEY', '0')
|
consumer_key = os.getenv('APIKEY', '0')
|
||||||
consumer_secret = os.getenv('CSECRET', '0')
|
consumer_secret = os.getenv('APISECRET', '0')
|
||||||
access_token = os.getenv('ATOKEN', '0')
|
access_token = os.getenv('ATOKEN', '0')
|
||||||
access_token_secret = os.getenv('ASECRET', '0')
|
access_token_secret = os.getenv('ASECRET', '0')
|
||||||
|
|
||||||
|
|||||||
+11
-4
@@ -1,5 +1,12 @@
|
|||||||
# Variables that contains the user credentials to access Twitter API
|
# Variables that contains the user credentials to access Twitter API
|
||||||
ACCESS_TOKEN = ""
|
import os
|
||||||
ACCESS_TOKEN_SECRET = ""
|
|
||||||
CONSUMER_KEY = ""
|
from dotenv import load_dotenv
|
||||||
CONSUMER_SECRET = ""
|
|
||||||
|
load_dotenv()
|
||||||
|
|
||||||
|
|
||||||
|
ACCESS_TOKEN = os.getenv('ATOKEN', '0')
|
||||||
|
ACCESS_TOKEN_SECRET = os.getenv('ASECRET', '0')
|
||||||
|
CONSUMER_KEY = os.getenv('APIKEY', '0')
|
||||||
|
CONSUMER_SECRET = os.getenv('APISECRET', '0')
|
||||||
|
|||||||
Reference in New Issue
Block a user