Validate ensure token important fields are valid
()
| 53 | |
| 54 | // Validate ensure token important fields are valid |
| 55 | func (t *Token) Validate() error { |
| 56 | err := t.credentialBase.validate() |
| 57 | if err != nil { |
| 58 | return err |
| 59 | } |
| 60 | if t.Value == "" { |
| 61 | return fmt.Errorf("missing value") |
| 62 | } |
| 63 | return nil |
| 64 | } |
| 65 | |
| 66 | func (t *Token) toConfig() map[string]string { |
| 67 | return map[string]string{ |
no test coverage detected