Skip to content

Commit

Permalink
replication: Check rule id before validating target arn (minio#1544)
Browse files Browse the repository at this point in the history
  • Loading branch information
poornas authored Sep 13, 2021
1 parent 617d530 commit f7d98f5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/replication/replication.go
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ func (c *Config) EditRule(opts Options) error {
if rule.Priority == newRule.Priority && rIdx != idx {
return fmt.Errorf("priority must be unique. Replication configuration already has a rule with this priority")
}
if rule.Destination.Bucket != newRule.Destination.Bucket {
if rule.Destination.Bucket != newRule.Destination.Bucket && rule.ID == newRule.ID {
return fmt.Errorf("invalid destination bucket for this rule")
}
}
Expand Down

0 comments on commit f7d98f5

Please sign in to comment.