diff --git a/moto/redshift/models.py b/moto/redshift/models.py index fd7c8b759..5da68fe67 100644 --- a/moto/redshift/models.py +++ b/moto/redshift/models.py @@ -237,10 +237,9 @@ class SnapshotCopyGrant(TaggableResourceMixin, BaseModel): resource_type = 'snapshotcopygrant' - def __init__(self, snapshot_copy_grant_name, kms_key_id, region_name): + def __init__(self, snapshot_copy_grant_name, kms_key_id): self.snapshot_copy_grant_name = snapshot_copy_grant_name self.kms_key_id = kms_key_id - self.region_name = region_name def to_json(self): return { @@ -590,20 +589,16 @@ class RedshiftBackend(BaseBackend): def create_snapshot_copy_grant(self, **kwargs): snapshot_copy_grant_name = kwargs['snapshot_copy_grant_name'] kms_key_id = kwargs['kms_key_id'] - region_name = kwargs['region_name'] if snapshot_copy_grant_name not in self.snapshot_copy_grants: - snapshot_copy_grant = SnapshotCopyGrant(snapshot_copy_grant_name, - kms_key_id, region_name) + snapshot_copy_grant = SnapshotCopyGrant(snapshot_copy_grant_name, kms_key_id) self.snapshot_copy_grants[snapshot_copy_grant_name] = snapshot_copy_grant return snapshot_copy_grant - raise SnapshotCopyGrantAlreadyExistsFaultError(snapshot_copy_grant_name) def delete_snapshot_copy_grant(self, **kwargs): snapshot_copy_grant_name = kwargs['snapshot_copy_grant_name'] if snapshot_copy_grant_name in self.snapshot_copy_grants: return self.snapshot_copy_grants.pop(snapshot_copy_grant_name) - raise SnapshotCopyGrantNotFoundFaultError(snapshot_copy_grant_name) def describe_snapshot_copy_grants(self, **kwargs):