mirror of
https://github.com/davidallendj/magellan.git
synced 2025-12-20 03:27:03 -07:00
Minor changes and fixes
This commit is contained in:
parent
6bf9035d96
commit
b873613939
4 changed files with 17 additions and 6 deletions
|
|
@ -68,7 +68,11 @@ func LoadAccessToken() (string, error) {
|
|||
}
|
||||
|
||||
// TODO: try to load token from config
|
||||
return "", fmt.Errorf("could not load from environment variable or file")
|
||||
testToken = viper.GetString("access_token")
|
||||
if testToken != "" {
|
||||
return testToken, nil
|
||||
}
|
||||
return "", fmt.Errorf("could not load token from environment variable, file, or config")
|
||||
}
|
||||
|
||||
func init() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue