Skip to content

Commit fb8780d

Browse files
committed
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.
1 parent 4c0797d commit fb8780d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

bukkit/src/main/java/com/github/games647/fastlogin/bukkit/task/FloodgateAuthTask.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,10 @@ public void run() {
7676
}
7777

7878
//decide if checks should be made for conflicting Java player names
79-
if (!isLinked &&
79+
if (!isLinked //linked players have the same name as their Java profile
80+
// if allowNameConflict is 'false' or 'linked' and the player had a conflicting
81+
// name, than they would have been kicked in FloodgateHook#checkNameConflict
82+
&& allowNameConflict.equals("true") &&
8083
(
8184
autoLoginFloodgate.equals("no-conflict")
8285
|| !isRegistered && autoRegisterFloodgate.equals("no-conflict"))

0 commit comments

Comments
 (0)