1
0
Fork 0
mirror of https://github.com/uhIgnacio/EmoteManager.git synced 2024-08-15 02:23:13 +00:00

fix 3.8 md5() compat

This commit is contained in:
io mintz 2021-04-06 04:31:47 +00:00
parent 042dc1cf98
commit da1e7abd09
3 changed files with 12 additions and 2 deletions

View file

@ -5,5 +5,6 @@ from . import archive
from . import emote
from . import errors
from . import paginator
from . import compat
# note: do not import .image in case the user doesn't want it
# since importing image can take a long time.

9
utils/compat.py Normal file
View file

@ -0,0 +1,9 @@
import hashlib
try:
hashlib.md5(usedforsecurity=False)
except TypeError:
md5 = hashlib.md5
else:
def md5(*args):
return hashlib.md5(*args, usedforsecurity=False)