diff options
author | Tobias Kellner <tobias.kellner@iaik.tugraz.at> | 2012-11-13 11:56:26 +0100 |
---|---|---|
committer | Tobias Kellner <tobias.kellner@iaik.tugraz.at> | 2012-11-13 11:56:26 +0100 |
commit | 1b9d5e1e569a8454132d268c3e9f1597bd5a20fc (patch) | |
tree | e19f42e9b81dc504e6f99936e78821ad253e95fc /trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/ConfigurationContainerImpl.java | |
parent | caf2ce502968c0e28d11be1c4f606178b3c44a15 (diff) | |
download | pdf-over-1b9d5e1e569a8454132d268c3e9f1597bd5a20fc.tar.gz pdf-over-1b9d5e1e569a8454132d268c3e9f1597bd5a20fc.tar.bz2 pdf-over-1b9d5e1e569a8454132d268c3e9f1597bd5a20fc.zip |
Guard against empty error messages
Diffstat (limited to 'trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/ConfigurationContainerImpl.java')
-rw-r--r-- | trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/ConfigurationContainerImpl.java | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/ConfigurationContainerImpl.java b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/ConfigurationContainerImpl.java index 1e8db610..8f1b1f9b 100644 --- a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/ConfigurationContainerImpl.java +++ b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/ConfigurationContainerImpl.java @@ -29,6 +29,7 @@ import org.slf4j.LoggerFactory; import at.asit.pdfover.gui.exceptions.InvalidEmblemFile; import at.asit.pdfover.gui.exceptions.InvalidNumberException; import at.asit.pdfover.gui.exceptions.InvalidPortException; +import at.asit.pdfover.gui.utils.Messages; import at.asit.pdfover.gui.workflow.states.mobilebku.ATrustHelper; import at.asit.pdfover.signator.BKUs; @@ -153,8 +154,12 @@ public class ConfigurationContainerImpl implements ConfigurationContainer { if(number == null || number.trim().equals("")) { //$NON-NLS-1$ this.mobileNumber = null; return; - } - this.mobileNumber = ATrustHelper.normalizeMobileNumber(number); + } + try { + this.mobileNumber = ATrustHelper.normalizeMobileNumber(number); + } catch (InvalidNumberException e) { + throw new InvalidNumberException(Messages.getString("error.InvalidPhoneNumber")); //$NON-NLS-1$ + } } |