add punctuation and comments for errors
This commit is contained in:
parent
2219488e84
commit
d664e29873
|
@ -114,9 +114,9 @@ This document describes the different errors Vikunja can return.
|
|||
| 6005 | 409 | The user is already a member of that team. |
|
||||
| 6006 | 400 | Cannot delete the last team member. |
|
||||
| 6007 | 403 | The team does not have access to the project to perform that action. |
|
||||
| 6008 | 400 | There are no teams found with that team name |
|
||||
| 6009 | 400 | There is no oidc team with that team name and oidcId |
|
||||
| 6010 | 400 | There are no oidc teams found for the user |
|
||||
| 6008 | 400 | There are no teams found with that team name. |
|
||||
| 6009 | 400 | There is no oidc team with that team name and oidcId. |
|
||||
| 6010 | 400 | There are no oidc teams found for the user. |
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -1217,6 +1217,7 @@ func (err ErrTeamDoesNotHaveAccessToProject) HTTPError() web.HTTPError {
|
|||
return web.HTTPError{HTTPCode: http.StatusForbidden, Code: ErrCodeTeamDoesNotHaveAccessToProject, Message: "This team does not have access to the project."}
|
||||
}
|
||||
|
||||
// ErrTeamsDoNotExist represents an error where Teams searched via non-unique name do not exist.
|
||||
type ErrTeamsDoNotExist struct {
|
||||
Name string
|
||||
}
|
||||
|
@ -1251,6 +1252,7 @@ func IsErrOIDCTeamDoesNotExist(err error) bool {
|
|||
return ok
|
||||
}
|
||||
|
||||
// ErrTeamDoesNotExist represents an error where a team does not exist
|
||||
func (err ErrOIDCTeamDoesNotExist) Error() string {
|
||||
return fmt.Sprintf("No Team with that name and valid property oidcId could be found [Team Name: %v] [OidcId : %v] ", err.Name, err.OidcID)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue