Skip to content

Commit

Permalink
Revert "I18n: use I18n for select helpers' prompt text"
Browse files Browse the repository at this point in the history
Broke CI.

[#2252 state:open]

This reverts commit adedf72.
  • Loading branch information
jeremy committed Aug 26, 2009
1 parent d672a14 commit a7ca559
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 28 deletions.
3 changes: 1 addition & 2 deletions actionpack/lib/action_view/helpers/form_options_helper.rb
Expand Up @@ -571,8 +571,7 @@ def add_options(option_tags, options, value = nil)
option_tags = "<option value=\"\">#{options[:include_blank] if options[:include_blank].kind_of?(String)}</option>\n" + option_tags
end
if value.blank? && options[:prompt]
prompt = options[:prompt].kind_of?(String) ? options[:prompt] : I18n.translate('support.select.prompt', :default => 'Please select')
"<option value=\"\">#{prompt}</option>\n" + option_tags
("<option value=\"\">#{options[:prompt].kind_of?(String) ? options[:prompt] : 'Please select'}</option>\n") + option_tags
else
option_tags
end
Expand Down
4 changes: 0 additions & 4 deletions actionpack/lib/action_view/locale/en.yml
Expand Up @@ -108,7 +108,3 @@
# The variable :count is also available
body: "There were problems with the following fields:"

support:
select:
# default value for :prompt => true in FormOptionsHelper
prompt: "Please select"
22 changes: 0 additions & 22 deletions actionpack/test/template/form_options_helper_i18n_test.rb

This file was deleted.

0 comments on commit a7ca559

Please sign in to comment.