mirror of
https://github.com/legop3/MultiRoombaRover.git
synced 2026-09-16 01:21:20 -04:00
stop people from switching to locked rovers...
This commit is contained in:
@@ -206,7 +206,7 @@ function requestControl(roverId, socket, options = {}) {
|
||||
if (!allowUser && !isAdmin(socket)) {
|
||||
throw new Error('Only admins can request control');
|
||||
}
|
||||
if (record.locked && !isAdmin(socket) && !allowUser) {
|
||||
if (record.locked && !isAdmin(socket)) {
|
||||
throw new Error('Rover locked');
|
||||
}
|
||||
const mode = getMode();
|
||||
|
||||
Reference in New Issue
Block a user