RemoveTopicByArn removes all topic configurations that match the exact specified ARN
(arn Arn)
| 352 | |
| 353 | // RemoveTopicByArn removes all topic configurations that match the exact specified ARN |
| 354 | func (b *Configuration) RemoveTopicByArn(arn Arn) { |
| 355 | var topics []TopicConfig |
| 356 | for _, topic := range b.TopicConfigs { |
| 357 | if topic.Topic != arn.String() { |
| 358 | topics = append(topics, topic) |
| 359 | } |
| 360 | } |
| 361 | b.TopicConfigs = topics |
| 362 | } |
| 363 | |
| 364 | // ErrNoConfigMatch is returned when a notification configuration (sqs,sns,lambda) is not found when trying to delete |
| 365 | var ErrNoConfigMatch = errors.New("no notification configuration matched") |