Skip to content

Commit

Permalink
some refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
nashby committed Dec 11, 2011
1 parent dc8c0dc commit 02ab9ae
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions lib/simple_form/components/errors.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,7 @@ def has_errors?
protected

def error_text
if options[:error_prefix]
options[:error_prefix] + " " + errors.send(error_method)
else
errors.send(error_method)
end
"#{options[:error_prefix]} #{errors.send(error_method)}".lstrip
end

def error_method
Expand Down

0 comments on commit 02ab9ae

Please sign in to comment.