add NS meta validation

This commit is contained in:
ghost 2023-12-18 00:15:52 +02:00
parent 2549a3d790
commit 5474175163

View File

@ -640,6 +640,19 @@ class RoomController extends AbstractController
);
}
// Validate meta NS
if (str_starts_with($name, '_'))
{
return $this->redirectToRoute(
'room_list',
[
'mode' => $request->get('mode'),
'name' => $name,
'error' => $translator->trans('Could not create namespace in meta area')
]
);
}
// Check room name not added before
$rooms = [];