Chore: move errors to enterprise (#32753)

This commit is contained in:
Alexander Zobnin 2021-04-07 17:33:08 +03:00 committed by GitHub
parent c1061d038c
commit 7a68852aa7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,22 +1,9 @@
package accesscontrol
import (
"errors"
"time"
)
var (
ErrRoleNotFound = errors.New("role not found")
ErrTeamRoleAlreadyAdded = errors.New("role is already added to this team")
ErrUserRoleAlreadyAdded = errors.New("role is already added to this user")
ErrTeamRoleNotFound = errors.New("team role not found")
ErrUserRoleNotFound = errors.New("user role not found")
ErrTeamNotFound = errors.New("team not found")
ErrPermissionNotFound = errors.New("permission not found")
ErrRoleFailedGenerateUniqueUID = errors.New("failed to generate role definition UID")
ErrVersionLE = errors.New("the provided role version is smaller than or equal to stored role")
)
// Role is the model for Role in RBAC.
type Role struct {
ID int64 `json:"id" xorm:"pk autoincr 'id'"`