Make Language#find_by_name case insensitive

This commit is contained in:
Joshua Peek
2011-05-09 22:28:56 -05:00
parent 0798411814
commit 34b8d422bd
2 changed files with 8 additions and 2 deletions

View File

@@ -7,13 +7,13 @@ module Linguist
def self.create(name)
language = new(name)
@name_index[language.name] = language
@name_index[language.name.downcase] = language
language
end
def self.find_by_name(name)
@name_index[name]
@name_index[name.downcase]
end
def self.[](name)