Skip to content

Commit

Permalink
Explicitly read files as utf8
Browse files Browse the repository at this point in the history
  • Loading branch information
sergeche committed Nov 19, 2019
1 parent ea2ef60 commit 9fb8e06
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion emmet/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

def read_json(file: str):
dirname = os.path.dirname(os.path.abspath(__file__))
with open(os.path.join(dirname, 'snippets', file), 'r') as f:
with open(os.path.join(dirname, 'snippets', file), 'r', encoding='utf8') as f:
return json.loads(f.read(None))


Expand Down
2 changes: 1 addition & 1 deletion emmet/markup/lorem/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

def read_json(file: str):
dirname = os.path.dirname(os.path.abspath(__file__))
with open(os.path.join(dirname, file), 'r') as f:
with open(os.path.join(dirname, file), 'r', encoding='utf8') as f:
return json.loads(f.read(None))

vocabularies = {
Expand Down

0 comments on commit 9fb8e06

Please sign in to comment.