mirror of
https://github.com/AuthMe/AuthMeReloaded.git
synced 2024-12-21 16:19:13 +01:00
- Set group to empty if permissions manager has no group support.
- edited comment for config node "permission.EnablePermissionCheck"
This commit is contained in:
parent
9726576907
commit
78708354e1
@ -87,7 +87,10 @@ public class PlayerDataStorage {
|
||||
public void saveData(Player player) {
|
||||
String id = Utils.getUUIDorName(player);
|
||||
Location location = spawnLoader.getPlayerLocationOrSpawn(player);
|
||||
String group = permissionsManager.getPrimaryGroup(player);
|
||||
String group = "";
|
||||
if (permissionsManager.hasGroupSupport()) {
|
||||
group = permissionsManager.getPrimaryGroup(player);
|
||||
}
|
||||
boolean operator = player.isOp();
|
||||
boolean canFly = player.getAllowFlight();
|
||||
float walkSpeed = player.getWalkSpeed();
|
||||
|
@ -156,10 +156,9 @@ public class LimboCache {
|
||||
}
|
||||
|
||||
private void restoreGroup(Player player, String group) {
|
||||
if (!settings.getProperty(PluginSettings.ENABLE_PERMISSION_CHECK)
|
||||
|| !permissionsManager.hasGroupSupport() || StringUtils.isEmpty(group)) {
|
||||
return;
|
||||
if (!StringUtils.isEmpty(group) && permissionsManager.hasGroupSupport()
|
||||
&& settings.getProperty(PluginSettings.ENABLE_PERMISSION_CHECK)) {
|
||||
permissionsManager.setGroup(player, group);
|
||||
}
|
||||
permissionsManager.setGroup(player, group);
|
||||
}
|
||||
}
|
||||
|
@ -45,8 +45,8 @@ public class PluginSettings implements SettingsClass {
|
||||
newProperty("settings.messagesLanguage", "en");
|
||||
|
||||
@Comment({
|
||||
"Take care with this option; if you don't want",
|
||||
"to use Vault and group switching of AuthMe",
|
||||
"Take care with this option; if you want",
|
||||
"to use group switching of AuthMe",
|
||||
"for unloggedIn players, set this setting to true.",
|
||||
"Default is false."
|
||||
})
|
||||
|
Loading…
Reference in New Issue
Block a user