Skip to content

Commit

Permalink
Merge 6357c04 into 5d35a59
Browse files Browse the repository at this point in the history
  • Loading branch information
pthompson127 committed Jul 21, 2020
2 parents 5d35a59 + 6357c04 commit ca9971b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions optimizely/optimizely_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@ def __init__(self, revision, experiments_map, features_map, datafile=None):
self.revision = revision
self.experiments_map = experiments_map
self.features_map = features_map
self.datafile = datafile
self._datafile = datafile

def get_datafile(self):
""" Get the datafile associated with OptimizelyConfig.
Returns:
A JSON string representation of the environment's datafile.
"""
return self.datafile
return self._datafile


class OptimizelyExperiment(object):
Expand Down
2 changes: 1 addition & 1 deletion optimizely/project_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def __init__(self, datafile, logger, error_handler):
"""

config = json.loads(datafile)
self._datafile = datafile
self._datafile = u'{}'.format(datafile)
self.logger = logger
self.error_handler = error_handler
self.version = config.get('version')
Expand Down
2 changes: 1 addition & 1 deletion tests/test_optimizely_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -456,7 +456,7 @@ def setUp(self):
}
},
'revision': '1',
'datafile': json.dumps(self.config_dict_with_features)
'_datafile': json.dumps(self.config_dict_with_features)
}

self.actual_config = self.opt_config_service.get_config()
Expand Down

0 comments on commit ca9971b

Please sign in to comment.