Skip to content

Commit

Permalink
Merge pull request #192 from projectsyn/bug/typed-nil-vault-client
Browse files Browse the repository at this point in the history
Fix typed nil assignment
  • Loading branch information
glrf authored Aug 10, 2021
2 parents ab5af1a + d0596c1 commit 02bf041
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions vault/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,13 @@ func NewClient(deletionPolicy synv1alpha1.DeletionPolicy, log logr.Logger) (Vaul
return instanceClient, nil
}

var err error
instanceClient, err = newBankVaultClient(deletionPolicy, log)

return instanceClient, err
c, err := newBankVaultClient(deletionPolicy, log)
if err != nil {
return nil, err
}
instanceClient = c

return instanceClient, nil
}

// SetCustomClient is used if a custom client needs to be used. Currently only
Expand Down

0 comments on commit 02bf041

Please sign in to comment.