Skip to content

Commit

Permalink
Change create options receiver to value instead of pointer.
Browse files Browse the repository at this point in the history
  • Loading branch information
annawinkler committed Jun 6, 2022
1 parent d332b90 commit bf8ef85
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 12 deletions.
5 changes: 1 addition & 4 deletions registry_provider.go
Expand Up @@ -219,10 +219,7 @@ func (r *registryProviders) Delete(ctx context.Context, providerID RegistryProvi
return r.client.do(ctx, req, nil)
}

func (o *RegistryProviderCreateOptions) valid() error {
if o == nil {
return nil
}
func (o RegistryProviderCreateOptions) valid() error {
if !validStringID(&o.Name) {
return ErrInvalidName
}
Expand Down
5 changes: 1 addition & 4 deletions registry_provider_platform.go
Expand Up @@ -212,10 +212,7 @@ func (id RegistryProviderPlatformID) valid() error {
return nil
}

func (o *RegistryProviderPlatformCreateOptions) valid() error {
if o == nil {
return nil
}
func (o RegistryProviderPlatformCreateOptions) valid() error {
if !validString(&o.OS) {
return ErrRequiredOS
}
Expand Down
5 changes: 1 addition & 4 deletions registry_provider_version.go
Expand Up @@ -259,10 +259,7 @@ func (o *RegistryProviderVersionListOptions) valid() error {
return nil
}

func (o *RegistryProviderVersionCreateOptions) valid() error {
if o == nil {
return nil
}
func (o RegistryProviderVersionCreateOptions) valid() error {
if !validStringID(&o.Version) {
return ErrInvalidVersion
}
Expand Down

0 comments on commit bf8ef85

Please sign in to comment.