heartcombo--simple_form/lib/simple_form/wrappers/single.rb

15 lines
322 B
Ruby
Raw Normal View History

2011-09-02 18:33:03 +00:00
module SimpleForm
module Wrappers
class Single < Many
def render(input)
options = input.options
if options[namespace] == false
nil
else
content = input.send(namespace)
wrap(input, options, content) if content
end
end
end
end
end