Fix crafty UI for vanilla java version OP and DeOp commands for Vanilla Java #679
What does this MR do and why?
Fixes
The current OP and De-Op buttons in the crafty web interface under Servers->ServerName->PlayerManagement are using "op Add" and "op remove" these commands are only for hytale and not vanilla server. Default commands are "op <Username>" and "deop <UserName>.
This fix adds a conditional display of the correct command using the following condition
data['server_stats']['server_type'] == "hytale"
Current behavior on clicking OP button give the following error
[23:45:43] [Server thread/INFO]: Incorrect argument for command
[23:45:43] [Server thread/INFO]: op add MYUSERNAME<--[HERE]
Screenshots or screen recordings
How to set up and validate locally
- Setup a vanilla java server (see version in screenshot above).
- Navigate to crafty web interface under Servers->ServerName->PlayerManagement
- Click OP button (See screen shot above)
- Expected user becomes op
Actual : ERROR in log
[23:45:43] [Server thread/INFO]: Incorrect argument for command
[23:45:43] [Server thread/INFO]: op add MYUSERNAME<--[HERE]
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
- Have you checked this doesn't interfere/conflict/duplicate someone elses work?
- Have you fully tested your changes?
- Have you resolved any lint issues?
- Have you assigned a reviewer?
- Have you applied correct labels?

