Skip to content

Commit d9a6b4c

Browse files
committed
Some linter cleanup
1 parent 49eb79d commit d9a6b4c

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/unstructured_client/users.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -548,7 +548,7 @@ def encrypt_secret(
548548
self,
549549
encryption_cert_or_key_pem: str,
550550
plaintext: str,
551-
type: Optional[str] = None,
551+
encryption_type: Optional[str] = None,
552552
) -> dict:
553553
"""
554554
Encrypts a plaintext string for securely sending to the Unstructured API.
@@ -581,11 +581,11 @@ def encrypt_secret(
581581
# If the plaintext is short, use RSA directly
582582
# Otherwise, use a RSA_AES envelope hybrid
583583
# The length of the public key is a good hueristic
584-
if not type:
585-
type = "rsa" if len(plaintext) <= len(public_key_pem) else "rsa_aes"
584+
if not encryption_type:
585+
encryption_type = "rsa" if len(plaintext) <= len(public_key_pem) else "rsa_aes"
586586

587-
if type == "rsa":
587+
if encryption_type == "rsa":
588588
return self._encrypt_rsa(public_key_pem, plaintext)
589-
else:
590-
return self._encrypt_rsa_aes(public_key_pem, plaintext)
589+
590+
return self._encrypt_rsa_aes(public_key_pem, plaintext)
591591
# endregion sdk-class-body

0 commit comments

Comments
 (0)