mirror of
https://github.com/AsamK/signal-cli
synced 2025-08-29 10:30:38 +00:00
Refactor register and verify
This commit is contained in:
parent
6c8a1ff3d3
commit
e74be0c345
33 changed files with 405 additions and 362 deletions
|
@ -4,12 +4,12 @@ import net.sourceforge.argparse4j.impl.Arguments;
|
|||
import net.sourceforge.argparse4j.inf.Namespace;
|
||||
import net.sourceforge.argparse4j.inf.Subparser;
|
||||
|
||||
import org.asamk.signal.manager.Manager;
|
||||
import org.asamk.signal.manager.RegistrationManager;
|
||||
import org.whispersystems.signalservice.api.push.exceptions.CaptchaRequiredException;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
public class RegisterCommand implements LocalCommand {
|
||||
public class RegisterCommand implements RegistrationCommand {
|
||||
|
||||
@Override
|
||||
public void attachToSubparser(final Subparser subparser) {
|
||||
|
@ -21,7 +21,7 @@ public class RegisterCommand implements LocalCommand {
|
|||
}
|
||||
|
||||
@Override
|
||||
public int handleCommand(final Namespace ns, final Manager m) {
|
||||
public int handleCommand(final Namespace ns, final RegistrationManager m) {
|
||||
try {
|
||||
final boolean voiceVerification = ns.getBoolean("voice");
|
||||
final String captcha = ns.getString("captcha");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue