String currentUserPropertyValue = userProperties.getPropertyValue(notificationType.getValue());
while (currentUserPropertyValue != null) {
userProperties.removePropertyValue(notificationType.getValue(), currentUserPropertyValue);
currentUserPropertyValue = userProperties.getPropertyValue(notificationType.getValue());
}
final NotificationTimestamp notificationTimestamp = NotificationTimestamp.fromType(notificationType);
String currentUserTimestamp = userProperties.getPropertyValue(notificationTimestamp.getValue());
if (currentUserTimestamp == null) {
userProperties.addPropertyValue(notificationTimestamp.getValue(), Long.toString(new Date().getTime()));
}
userProperties.addPropertyValue(notificationType.getValue(), notificationInterval.getValue());
}