mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Feature detect based on Ruby version.
I didn't want to do this, FNM_EXTGLOB is defined on 2.1.x, but Dir.glob returns the wrong value on Ruby less than 2.2.0. Checking for a case-insensitive FS seems too hard, so just check Ruby version Checking for a case-insensitive FS seems too hard, so just check Ruby version.
This commit is contained in:
parent
623da13256
commit
239f560630
1 changed files with 1 additions and 1 deletions
|
@ -196,7 +196,7 @@ module ActionView
|
|||
}
|
||||
end
|
||||
|
||||
if File.const_defined? :FNM_EXTGLOB
|
||||
if RUBY_VERSION >= '2.2.0'
|
||||
def find_template_paths(query)
|
||||
Dir[query].reject { |filename|
|
||||
File.directory?(filename) ||
|
||||
|
|
Loading…
Reference in a new issue