Island: Add note about encryption decorator in

MongoCredentialsRepository
This commit is contained in:
Mike Salvatore 2022-07-12 13:23:38 -04:00
parent cee52ab12c
commit fe7188798f
1 changed files with 3 additions and 0 deletions

View File

@ -74,6 +74,9 @@ class MongoCredentialsRepository(ICredentialsRepository):
# NOTE: The encryption/decryption is complicated and also full of mostly duplicated code. Rather
# than spend the effort to improve them now, we can revisit them when we resolve #2072.
# Resolving #2072 will make it easier to simplify these methods and remove duplication.
#
# If possible, implement the encryption/decryption as a decorator so it can be reused with
# different ICredentialsRepository implementations
def _encrypt_credentials_mapping(self, mapping: Mapping[str, Any]) -> Mapping[str, Any]:
encrypted_mapping: Dict[str, Any] = {}