Skip to content

Commit

Permalink
Resolve package and variable name collision
Browse files Browse the repository at this point in the history
  • Loading branch information
Adirio committed Jan 7, 2020
1 parent cf6cec4 commit ae308ba
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pkg/scaffold/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -283,10 +283,10 @@ func (api *API) validateResourceGroup(r *resource.Resource) error {
// resourceExists returns true if API resource is already tracked by the PROJECT file.
// Note that this works only for v2, since in v1 resources are not tracked by the PROJECT file.
func (api *API) resourceExists() bool {
for _, resource := range api.project.Resources {
if resource.Group == api.Resource.Group &&
resource.Version == api.Resource.Version &&
resource.Kind == api.Resource.Kind {
for _, r := range api.project.Resources {
if r.Group == api.Resource.Group &&
r.Version == api.Resource.Version &&
r.Kind == api.Resource.Kind {
return true
}
}
Expand Down

0 comments on commit ae308ba

Please sign in to comment.