mirror of
https://github.com/filebrowser/filebrowser.git
synced 2025-05-08 19:22:57 +00:00
fix: don't expose scope for non-admin users
This commit is contained in:
parent
c1987237d0
commit
0942fc7042
@ -94,6 +94,9 @@ var userGetHandler = withSelfOrAdmin(func(w http.ResponseWriter, r *http.Request
|
|||||||
}
|
}
|
||||||
|
|
||||||
u.Password = ""
|
u.Password = ""
|
||||||
|
if !u.Perm.Admin {
|
||||||
|
u.Scope = ""
|
||||||
|
}
|
||||||
return renderJSON(w, r, u)
|
return renderJSON(w, r, u)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user