diff --git a/monkey/common/credentials/encoding.py b/monkey/common/credentials/encoding.py index e76ff8599..b5b58ec53 100644 --- a/monkey/common/credentials/encoding.py +++ b/monkey/common/credentials/encoding.py @@ -5,7 +5,7 @@ from typing import Optional, Union from pydantic import SecretBytes, SecretStr -def get_plaintext(secret: Union[SecretStr, SecretBytes, None, str]) -> Optional[str]: +def get_plaintext(secret: Union[SecretStr, SecretBytes, None, str]) -> Optional[Union[str, bytes]]: if isinstance(secret, (SecretStr, SecretBytes)): return secret.get_secret_value() else: