Skip to content

Commit cd6f742

Browse files
committed
add greater than check
1 parent 7910244 commit cd6f742

File tree

1 file changed

+1
-1
lines changed
  • localstack-core/localstack/services/kms

1 file changed

+1
-1
lines changed

localstack-core/localstack/services/kms/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -705,7 +705,7 @@ def _get_key_usage(self, request_key_usage: str, key_spec: str) -> str:
705705
return request_key_usage or "ENCRYPT_DECRYPT"
706706

707707
def rotate_key_on_demand(self):
708-
if len(self.previous_keys) == ON_DEMAND_ROTATION_LIMIT:
708+
if len(self.previous_keys) >= ON_DEMAND_ROTATION_LIMIT:
709709
raise LimitExceededException(
710710
f"The on-demand rotations limit has been reached for the given keyId. "
711711
f"No more on-demand rotations can be performed for this key: {self.metadata['Arn']}"

0 commit comments

Comments
 (0)