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