mirror of
https://github.com/m1k1o/neko.git
synced 2024-07-24 14:40:50 +12:00
add locked controls to settings.
This commit is contained in:
@ -40,6 +40,10 @@ func (h *MessageHandlerCtx) controlRequest(session types.Session) error {
|
||||
return ErrIsAlreadyTheHost
|
||||
}
|
||||
|
||||
if h.sessions.Settings().LockedControls && !session.Profile().IsAdmin {
|
||||
return ErrIsNotAllowedToHost
|
||||
}
|
||||
|
||||
if !h.sessions.Settings().ImplicitHosting {
|
||||
// tell session if there is a host
|
||||
if host, hasHost := h.sessions.GetHost(); hasHost {
|
||||
|
Reference in New Issue
Block a user