Skip to content

Commit

Permalink
bug fix, changed LOKOLE_STSTATE_DIRECTORY to OPWEN (#545)
Browse files Browse the repository at this point in the history
  • Loading branch information
adamsclafani authored May 13, 2021
1 parent 63444b4 commit 2785a32
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions opwen_email_client/webapp/forms/register.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,14 @@ def _setup_client(self, path):
response = post(client_create_url,
json={'domain': client_domain},
headers={'Authorization': 'Bearer {}'.format(token)})
if response.status != 200:
if response.status_code != 200:
raise ValidationError(i8n.FAILED_REGISTRATION)
register.delay(name, token, path)

def _setup_path(self):
home = Path.home()
user = home.parts[-1]
path = (Path(getenv('LOKOLE_STATE_DIRECTORY', 'lokole/state')) / 'settings.env').absolute()
path = (Path(getenv('OPWEN_STATE_DIRECTORY', 'lokole/state')) / 'settings.env').absolute()
parent = path.parent
parent.mkdir(parents=True, exist_ok=True)
is_in_home = parent.parts[:3] == home.parts
Expand Down

0 comments on commit 2785a32

Please sign in to comment.