mirror of
https://github.com/appleboy/drone-jenkins.git
synced 2026-06-04 10:15:02 +08:00
style: streamline authentication error handling in config validation
- Simplify authentication error message in config validation Signed-off-by: appleboy <appleboy.tw@gmail.com>
This commit is contained in:
@@ -94,7 +94,7 @@ func (p Plugin) validateConfig() error {
|
||||
hasRemoteToken := p.RemoteToken != ""
|
||||
|
||||
if !hasUserAuth && !hasRemoteToken {
|
||||
return errors.New("authentication required: provide either (user + token) or remote-token")
|
||||
return errors.New("authentication required")
|
||||
}
|
||||
|
||||
return nil
|
||||
|
||||
Reference in New Issue
Block a user