Email verification code (#1382)
* Base verification code implementation, must define command, manager, events * VerificationManager, verification command and messages, handled some sensible commands, configuration values * Improved manager and sensible commands trigger * Updated messages * Updated verification code manager, fixed tests * Switched to a permission based command * Verification manager and command improved and added tests * Edited messages
This commit is contained in:
@@ -40,6 +40,7 @@ import fr.xephi.authme.command.executable.login.LoginCommand;
|
||||
import fr.xephi.authme.command.executable.logout.LogoutCommand;
|
||||
import fr.xephi.authme.command.executable.register.RegisterCommand;
|
||||
import fr.xephi.authme.command.executable.unregister.UnregisterCommand;
|
||||
import fr.xephi.authme.command.executable.verification.VerificationCommand;
|
||||
import fr.xephi.authme.permission.AdminPermission;
|
||||
import fr.xephi.authme.permission.DebugSectionPermissions;
|
||||
import fr.xephi.authme.permission.PlayerPermission;
|
||||
@@ -136,13 +137,24 @@ public class CommandInitializer {
|
||||
CommandDescription captchaBase = CommandDescription.builder()
|
||||
.parent(null)
|
||||
.labels("captcha")
|
||||
.description("Captcha Command")
|
||||
.description("Captcha command")
|
||||
.detailedDescription("Captcha command for AuthMeReloaded.")
|
||||
.withArgument("captcha", "The Captcha", false)
|
||||
.permission(PlayerPermission.CAPTCHA)
|
||||
.executableCommand(CaptchaCommand.class)
|
||||
.register();
|
||||
|
||||
// Register the base verification code command
|
||||
CommandDescription verificationBase = CommandDescription.builder()
|
||||
.parent(null)
|
||||
.labels("verification")
|
||||
.description("Verification command")
|
||||
.detailedDescription("Command to complete the verification process for AuthMeReloaded.")
|
||||
.withArgument("code", "The code", false)
|
||||
.permission(PlayerPermission.VERIFICATION_CODE)
|
||||
.executableCommand(VerificationCommand.class)
|
||||
.register();
|
||||
|
||||
List<CommandDescription> baseCommands = ImmutableList.of(
|
||||
authMeBase,
|
||||
emailBase,
|
||||
@@ -151,7 +163,8 @@ public class CommandInitializer {
|
||||
registerBase,
|
||||
unregisterBase,
|
||||
changePasswordBase,
|
||||
captchaBase);
|
||||
captchaBase,
|
||||
verificationBase);
|
||||
|
||||
setHelpOnAllBases(baseCommands);
|
||||
commands = baseCommands;
|
||||
|
||||
Reference in New Issue
Block a user