use pathlib version of open

This commit is contained in:
Sarah Hoffmann
2021-04-23 21:57:05 +02:00
parent d5fc3b5e99
commit 280406c0d7

View File

@@ -116,7 +116,7 @@ class SpecialPhrasesImporter():
if self.config.PHRASE_CONFIG:
settings_path = self._convert_php_settings_if_needed(self.config.PHRASE_CONFIG)
with open(settings_path, "r") as json_settings:
with settings_path.open("r") as json_settings:
settings = json.load(json_settings)
return settings['blackList'], settings['whiteList']