forked from p15670423/monkey
Fixed a type-hint for a config decryption method
This commit is contained in:
parent
53bb6f7879
commit
c487a278fe
|
@ -2,7 +2,7 @@ import base64
|
||||||
import io
|
import io
|
||||||
import json
|
import json
|
||||||
import logging
|
import logging
|
||||||
from typing import Dict, Union
|
from typing import Dict
|
||||||
|
|
||||||
import pyAesCrypt
|
import pyAesCrypt
|
||||||
|
|
||||||
|
@ -27,7 +27,7 @@ def encrypt_config(config: Dict, password: str) -> str:
|
||||||
return ciphertext_b64.decode()
|
return ciphertext_b64.decode()
|
||||||
|
|
||||||
|
|
||||||
def decrypt_config(cyphertext: Union[str, dict], password: str) -> Dict:
|
def decrypt_config(cyphertext: str, password: str) -> Dict:
|
||||||
if not password:
|
if not password:
|
||||||
raise NoCredentialsError
|
raise NoCredentialsError
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue