Skip to content
This repository has been archived by the owner on Dec 28, 2024. It is now read-only.

Commit

Permalink
Merge pull request #7 from vascoosx/develop
Browse files Browse the repository at this point in the history
avoid error when using module for the first time
  • Loading branch information
spencergibb committed May 12, 2014
2 parents 54c5917 + 7672576 commit 7a10ae7
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions share/library/mac_pkg
Original file line number Diff line number Diff line change
Expand Up @@ -519,9 +519,11 @@ class Installer(object):

tempdir = tempfile.gettempdir()
extra_vars_path = path.join(tempdir, "battleschool_extra_vars.json")
with open(extra_vars_path) as f:
extra_vars = json.load(f)

if path.isfile(extra_vars_path):
with open(extra_vars_path) as f:
extra_vars = json.load(f)
else:
extra_vars = {}

def get_env(name, default, converter = None):
if name in extra_vars:
Expand Down

0 comments on commit 7a10ae7

Please sign in to comment.