#443 Use correct message to ask to add email after login

This commit is contained in:
ljacqu 2016-02-27 12:18:04 +01:00
parent 1b818bd833
commit e79f325411
2 changed files with 6 additions and 5 deletions

View File

@ -50,6 +50,7 @@ import fr.xephi.authme.settings.Settings;
import fr.xephi.authme.settings.SettingsMigrationService;
import fr.xephi.authme.settings.Spawn;
import fr.xephi.authme.settings.properties.DatabaseSettings;
import fr.xephi.authme.settings.properties.EmailSettings;
import fr.xephi.authme.settings.properties.HooksSettings;
import fr.xephi.authme.settings.properties.PluginSettings;
import fr.xephi.authme.settings.properties.RestrictionSettings;
@ -786,7 +787,7 @@ public class AuthMe extends JavaPlugin {
public void run() {
for (PlayerAuth auth : database.getLoggedPlayers()) {
String email = auth.getEmail();
if (email == null || email.isEmpty() || email.equalsIgnoreCase("your@email.com")) {
if (StringUtils.isEmpty(email) || email.equalsIgnoreCase("your@email.com")) {
Player player = Utils.getPlayer(auth.getRealName());
if (player != null) {
messages.send(player, MessageKey.ADD_EMAIL_MESSAGE);
@ -794,7 +795,7 @@ public class AuthMe extends JavaPlugin {
}
}
}
}, 1, 1200 * Settings.delayRecall);
}, 1, 1200 * newSettings.getProperty(EmailSettings.DELAY_RECALL));
}
public String replaceAllInfo(String message, Player player) {

View File

@ -175,7 +175,7 @@ public class AsynchronousLogin {
displayOtherAccounts(auth);
if (Settings.recallEmail && (StringUtils.isEmpty(email) || "your@email.com".equalsIgnoreCase(email))) {
m.send(player, MessageKey.EMAIL_ADDED_SUCCESS);
m.send(player, MessageKey.ADD_EMAIL_MESSAGE);
}
if (!Settings.noConsoleSpam) {