MCPcopy Create free account
hub / github.com/eventure/hide.client.linux / Check

Method Check

rest/accessTokenRequest.go:15–24  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

13}
14
15func ( a *AccessTokenRequest ) Check() ( err error ) {
16 if len( a.Domain ) == 0 { err = errors.New( "no domain" ); return }
17 if len ( a.AccessToken ) == 0 { // No access token, check username/password
18 if len( a.Username ) == 0 { err = errors.New( "no username" ); return }
19 if len( a.Username ) > 64 { err = errors.New( "too many characters in username" ); return }
20 if len( a.Password ) == 0 { err = errors.New( "no password" ); return }
21 if len( a.Password ) > 64 { err = errors.New( "too many characters in password" ); return }
22 }
23 return
24}

Callers 1

GetAccessTokenMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected