mirror of
https://github.com/GeyserMC/Geyser.git
synced 2025-12-19 14:59:27 +00:00
Don't try to show the server settings form to players who are not logged in (#4387)
* Don't show the server settings form to players who are not yet logged in * Add brackets to if statement
This commit is contained in:
@@ -42,6 +42,11 @@ public class BedrockServerSettingsRequestTranslator extends PacketTranslator<Ser
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void translate(GeyserSession session, ServerSettingsRequestPacket packet) {
|
public void translate(GeyserSession session, ServerSettingsRequestPacket packet) {
|
||||||
|
// UUID is null when we're not logged in, which causes the hasPermission check to fail
|
||||||
|
if (!session.isLoggedIn()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
CustomForm form = SettingsUtils.buildForm(session);
|
CustomForm form = SettingsUtils.buildForm(session);
|
||||||
int formId = session.getFormCache().addForm(form);
|
int formId = session.getFormCache().addForm(form);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user