Skip to content

Commit e7cb208

Browse files
committed
Cleanup
1 parent ac51022 commit e7cb208

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

lib/bootstrap_form/components/validation.rb

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,7 @@ def presence_validators?(target, object, attribute)
4747
end
4848

4949
def call_with_self(object, proc)
50-
if proc.is_a? Symbol
51-
proc = object.method(proc)
52-
end
50+
proc = object.method(proc) if proc.is_a? Symbol
5351
object.instance_exec(*[(object if proc.arity >= 1)].compact, &proc)
5452
end
5553

lib/bootstrap_form/form_group.rb

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,8 @@ def form_group(*args, &block)
1010

1111
options[:class] = form_group_classes(options)
1212

13-
tag.div(**options.except(:append, :id, :label, :help, :icon,
14-
:input_group_class, :label_col, :control_col,
15-
:add_control_col_class, :layout, :prepend, :floating)) do
13+
tag.div(**options.except(:add_control_col_class, :append, :control_col, :floating, :help, :icon, :id,
14+
:input_group_class, :label, :label_col, :layout, :prepend)) do
1615
label = generate_label(options[:id], name, options[:label], options[:label_col], options[:layout])
1716
form_group_content(label, generate_help(name, options[:help]), options, &block)
1817
end

0 commit comments

Comments
 (0)