Skip to content

Commit

Permalink
Merge pull request #27 from toddrob99/dont-assume-working-dir
Browse files Browse the repository at this point in the history
Don't assume working directory
  • Loading branch information
mattabullock authored Aug 27, 2016
2 parents 92d822d + 76a4fbc commit b53798a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ def __init__(self):
self.POST_THREAD_SETTINGS = None

def read_settings(self):
with open('settings.json') as data:
import os
cwd = os.path.dirname(os.path.realpath(__file__))
with open(cwd + '/settings.json') as data:
settings = json.load(data)

self.CLIENT_ID = settings.get('CLIENT_ID')
Expand Down

0 comments on commit b53798a

Please sign in to comment.