feat: 数据库直连操作权限
This commit is contained in:
1 parent
c6eed87f40
commit
e95679ea4b
3 files changed
+50
-32
No files matched your search
@@ -42,7 +42,7 @@ func IsAdmin(userID string) bool {
|
||||
}
|
||||
// 从本地配置获取user信息
|
||||
// admins := Get("user.adminList").([]any)
|
||||
admins := []string{"1"}
|
||||
admins := []string{"1", "2", "3"}
|
||||
for _, s := range admins {
|
||||
if s == userID {
|
||||
return true
|
||||
|
||||
Reference in new issue
Block a user