public void Modify(ElementRequest request, IFieldValidationRule rule)
        {
            var messages = request.CurrentTag.Data(LocalizationKey) as ElementLocalizationMessages;
            if (messages == null)
            {
                messages = new ElementLocalizationMessages();
                request.CurrentTag.Data(LocalizationKey, messages);
            }

            messages.Add(rule);
        }
        public void Modify(ElementRequest request, IFieldValidationRule rule)
        {
            var messages = request.CurrentTag.Data(LocalizationKey) as ElementLocalizationMessages;

            if (messages == null)
            {
                messages = new ElementLocalizationMessages();
                request.CurrentTag.Data(LocalizationKey, messages);
            }

            messages.Add(rule);
        }