mirror of
https://github.com/pomerium/pomerium.git
synced 2025-05-02 20:06:03 +02:00
fix not obtaining correct gitlab url because of empty string (#2044)
This commit is contained in:
parent
d7ab817de7
commit
c96ff595e5
1 changed files with 5 additions and 1 deletions
|
@ -59,7 +59,11 @@ func GetProvider(options Options) (provider Provider) {
|
|||
globalProvider.options = options
|
||||
}()
|
||||
|
||||
providerURL, _ := url.Parse(options.ProviderURL)
|
||||
var providerURL *url.URL
|
||||
// url.Parse will succeed even if we pass an empty string
|
||||
if options.ProviderURL != "" {
|
||||
providerURL, _ = url.Parse(options.ProviderURL)
|
||||
}
|
||||
switch options.Provider {
|
||||
case auth0.Name:
|
||||
serviceAccount, err := auth0.ParseServiceAccount(options)
|
||||
|
|
Loading…
Add table
Reference in a new issue