From 29b6f2ad9b8ec93a2d51bad2fdd7a11176068f40 Mon Sep 17 00:00:00 2001 From: Jakob Heher Date: Wed, 15 Jun 2022 13:38:56 +0200 Subject: return username unchanged if it doesn't look like a phone number, cf. #88 --- .../configuration/SimpleConfigurationComposite.java | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) (limited to 'pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/configuration') diff --git a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/configuration/SimpleConfigurationComposite.java b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/configuration/SimpleConfigurationComposite.java index 2f2fef0e..a2973c3d 100644 --- a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/configuration/SimpleConfigurationComposite.java +++ b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/configuration/SimpleConfigurationComposite.java @@ -62,7 +62,6 @@ import at.asit.pdfover.gui.controls.Dialog.BUTTONS; import at.asit.pdfover.gui.controls.ErrorDialog; import at.asit.pdfover.gui.controls.ErrorMarker; import at.asit.pdfover.gui.exceptions.InvalidEmblemFile; -import at.asit.pdfover.gui.exceptions.InvalidNumberException; import at.asit.pdfover.gui.utils.ImageConverter; import at.asit.pdfover.gui.workflow.config.ConfigManipulator; import at.asit.pdfover.gui.workflow.config.ConfigurationContainer; @@ -585,10 +584,7 @@ public class SimpleConfigurationComposite extends ConfigurationCompositeBase { this.setSignatureProfileSetting(); } - /** - * @throws InvalidNumberException - */ - private void plainMobileNumberSetter() throws InvalidNumberException { + private void plainMobileNumberSetter() { String number = this.txtMobileNumber.getText(); this.configurationContainer.setMobileNumber(number); number = this.configurationContainer.getMobileNumber(); @@ -620,12 +616,8 @@ public class SimpleConfigurationComposite extends ConfigurationCompositeBase { */ @Override public void initConfiguration(PersistentConfigProvider provider) { - try { - this.configurationContainer.setMobileNumber( - provider.getDefaultMobileNumberPersistent()); - } catch (InvalidNumberException e) { - log.error("Failed to set mobile phone number!", e); //$NON-NLS-1$ - } + this.configurationContainer.setMobileNumber( + provider.getDefaultMobileNumberPersistent()); try { this.configurationContainer.setEmblem( -- cgit v1.2.3