if (null == contact) {
// Abort here
throw new NullPointerException("contact is null");
- } else if (contact.getGender() == null) {
+ } else if (contact.getContactGender() == null) {
// Gender is not set
throw new NullPointerException(MessageFormat.format("contact {0} has no gender set.", contact));
}
// Get key from it
- String key = contact.getGender().getMessageKey();
+ String key = contact.getContactGender().getMessageKey();
// Translate and return it
return utils.getMessageStringFromKey(key);