You've already forked AstralRinth
forked from didirus/AstralRinth
Move many things over from Knossos (and other rearrangements) (#102)
This commit is contained in:
11
lib/helpers/users.js
Normal file
11
lib/helpers/users.js
Normal file
@@ -0,0 +1,11 @@
|
||||
// noinspection JSUnusedGlobalSymbols
|
||||
|
||||
export const getUserLink = (user) => {
|
||||
return `/user/${user.username}`
|
||||
}
|
||||
|
||||
export const isStaff = (user) => {
|
||||
return user && STAFF_ROLES.includes(user.role)
|
||||
}
|
||||
|
||||
export const STAFF_ROLES = ['moderator', 'admin']
|
||||
Reference in New Issue
Block a user