feat: send commands too
License: MIT Signed-off-by: Henrique Dias <hacdias@gmail.com>
This commit is contained in:
parent
bc7464d3f5
commit
cca1eac74e
@ -84,6 +84,7 @@ type userInfo struct {
|
||||
Locale string `json:"locale"`
|
||||
ViewMode types.ViewMode `json:"viewMode"`
|
||||
Perm types.Permissions `json:"perm"`
|
||||
Commands []string `json:"commands"`
|
||||
LockPassword bool `json:"lockPassword"`
|
||||
}
|
||||
|
||||
@ -143,6 +144,7 @@ func (e *Env) printToken(w http.ResponseWriter, r *http.Request, user *types.Use
|
||||
ViewMode: user.ViewMode,
|
||||
Perm: user.Perm,
|
||||
LockPassword: user.LockPassword,
|
||||
Commands: user.Commands,
|
||||
},
|
||||
StandardClaims: jwt.StandardClaims{
|
||||
ExpiresAt: time.Now().Add(time.Hour * 24).Unix(),
|
||||
|
||||
@ -7,6 +7,8 @@ type Store struct {
|
||||
Share ShareStore
|
||||
}
|
||||
|
||||
// TODO: wrappers to verify
|
||||
|
||||
// UsersStore is used to manage users relativey to a data storage.
|
||||
type UsersStore interface {
|
||||
Get(id uint) (*User, error)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user