Prevent duplicate name check API call

Previously: If allowFloodgateNameConflict = false or linked and either autoLoginFloodgate or
autoRegisterFloodgate is set to no-conflict and a player with a non-conflicting name
connects then there will be a double check.
This commit is contained in:
Smart123s
2021-05-22 21:04:35 +02:00
parent 4c0797d5ea
commit fb8780d006

View File

@ -76,7 +76,10 @@ public class FloodgateAuthTask implements Runnable {
}
//decide if checks should be made for conflicting Java player names
if (!isLinked &&
if (!isLinked //linked players have the same name as their Java profile
// if allowNameConflict is 'false' or 'linked' and the player had a conflicting
// name, than they would have been kicked in FloodgateHook#checkNameConflict
&& allowNameConflict.equals("true") &&
(
autoLoginFloodgate.equals("no-conflict")
|| !isRegistered && autoRegisterFloodgate.equals("no-conflict"))