diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2013-12-19 17:27:52 -0200 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2013-12-19 17:28:19 -0200 |
commit | 04ad814bb992e854927c1bec3422df882f017ab6 (patch) | |
tree | aa8de9544c4054df1cc47647b6f7851067334545 /activesupport/lib/active_support | |
parent | bfdae1775a298a4240c32e87d84ea7e8c6dccb06 (diff) | |
download | rails-04ad814bb992e854927c1bec3422df882f017ab6.tar.gz rails-04ad814bb992e854927c1bec3422df882f017ab6.tar.bz2 rails-04ad814bb992e854927c1bec3422df882f017ab6.zip |
Make sure multiline string is not accepted by the regexp
Diffstat (limited to 'activesupport/lib/active_support')
-rw-r--r-- | activesupport/lib/active_support/configurable.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activesupport/lib/active_support/configurable.rb b/activesupport/lib/active_support/configurable.rb index bafcadff9a..3dd44e32d8 100644 --- a/activesupport/lib/active_support/configurable.rb +++ b/activesupport/lib/active_support/configurable.rb @@ -107,7 +107,7 @@ module ActiveSupport options = names.extract_options! names.each do |name| - raise NameError.new('invalid config attribute name') unless name =~ /\A[_A-Za-z]\w*\Z/ + raise NameError.new('invalid config attribute name') unless name =~ /\A[_A-Za-z]\w*\z/ reader, reader_line = "def #{name}; config.#{name}; end", __LINE__ writer, writer_line = "def #{name}=(value); config.#{name} = value; end", __LINE__ |