Skip to content

Commit

Permalink
fix(sub): set subscription to failed if there's no catalogsource
Browse files Browse the repository at this point in the history
  • Loading branch information
ecordell committed Dec 18, 2018
1 parent 7977ada commit bab4c84
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/controller/operators/catalog/subscriptions.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func (o *Operator) syncSubscription(in *v1alpha1.Subscription) (*v1alpha1.Subscr
}
catalog, ok := o.sources[registry.ResourceKey{Name: out.Spec.CatalogSource, Namespace: catalogNamespace}]
if !ok {
out.Status.State = v1alpha1.SubscriptionStateAtLatest
out.Status.State = v1alpha1.SubscriptionStateFailed
out.Status.Reason = v1alpha1.SubscriptionReasonInvalidCatalog
return out, fmt.Errorf("unknown catalog source %s in namespace %s", out.Spec.CatalogSource, catalogNamespace)
}
Expand Down

0 comments on commit bab4c84

Please sign in to comment.