1
Fork 0
mirror of https://github.com/jech/galene.git synced 2024-11-22 08:35:57 +01:00

Simplify syntax of permissionsMap.

This commit is contained in:
Juliusz Chroboczek 2024-06-02 01:45:51 +02:00
parent 8db2e92cb9
commit ddcb9ed0cc

View file

@ -26,11 +26,11 @@ type Permissions struct {
}
var permissionsMap = map[string][]string{
"op": []string{"op", "present", "message", "token"},
"present": []string{"present", "message"},
"message": []string{"message"},
"observe": []string{},
"admin": []string{"admin"},
"op": {"op", "present", "message", "token"},
"present": {"present", "message"},
"message": {"message"},
"observe": {},
"admin": {"admin"},
}
func NewPermissions(name string) (Permissions, error) {