formtastic_extensions 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.5
|
@@ -12,7 +12,7 @@ module FormtasticExtensions
|
|
12
12
|
options[:as] ||= default_input_type(method)
|
13
13
|
|
14
14
|
html_class = [ options[:as], (options[:required] ? :required : :optional) ]
|
15
|
-
html_class << 'error' if @object && @object.respond_to?(:errors) &&
|
15
|
+
html_class << 'error' if @object && @object.respond_to?(:errors) && !@object.errors[method.to_sym].blank?
|
16
16
|
|
17
17
|
wrapper_html = options.delete(:wrapper_html) || {}
|
18
18
|
wrapper_html[:id] ||= generate_html_id(method)
|