Skip to content

Commit 3da8a27

Browse files
committed
Save some lines of code
1 parent f5475ec commit 3da8a27

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

latextools/utils/cache.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,7 @@ def hash_digest(text):
5050
Arguments:
5151
text -- the text for which the digest should be created
5252
"""
53-
text_encoded = text.encode("utf8")
54-
hash_result = hashlib.md5(text_encoded)
55-
return hash_result.hexdigest()
53+
return hashlib.md5(text.encode("utf-8")).hexdigest()
5654

5755

5856
def cache_local(tex_root, key, func):

0 commit comments

Comments
 (0)