// Init instance
DialableMobileNumber mobileNumber = null;
+ // Is the instance there?
+ if (null == MOBILE_LIST_CONTROLLER) {
+ // Get bean from CDI directly
+ MOBILE_LIST_CONTROLLER = CDI.current().select(JobssMobileListWebViewBean.class).get();
+ }
+
try {
// Try to parse the value as long
final Long mobileNumberId = Long.valueOf(submittedValue);
- // Is the instance there?
- if (null == MOBILE_LIST_CONTROLLER) {
- // Get bean from CDI directly
- MOBILE_LIST_CONTROLLER = CDI.current().select(JobsMobileListWebViewBean.class).get();
- }
-
// Try to get mobile instance from it
mobileNumber = MOBILE_LIST_CONTROLLER.findMobileNumberById(mobileNumberId);
} catch (final NumberFormatException ex) {