mirror of
https://github.com/binwiederhier/ntfy.git
synced 2025-05-31 10:39:23 +02:00
More review stuff
This commit is contained in:
parent
d8dd4c92bf
commit
79f9e78c37
2 changed files with 7 additions and 7 deletions
user
|
@ -32,13 +32,13 @@ func (u *User) TierID() string {
|
|||
return u.Tier.ID
|
||||
}
|
||||
|
||||
// Admin returns true if the user is an admin
|
||||
func (u *User) Admin() bool {
|
||||
// IsAdmin returns true if the user is an admin
|
||||
func (u *User) IsAdmin() bool {
|
||||
return u != nil && u.Role == RoleAdmin
|
||||
}
|
||||
|
||||
// User returns true if the user is a regular user, not an admin
|
||||
func (u *User) User() bool {
|
||||
// IsUser returns true if the user is a regular user, not an admin
|
||||
func (u *User) IsUser() bool {
|
||||
return u != nil && u.Role == RoleUser
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue