Case-insensitive Bot::get

This commit is contained in:
Jaiden Mispy 2016-08-21 23:37:44 +10:00
parent 50daa5ab03
commit 75566103d4

View file

@ -168,7 +168,7 @@ module Ebooks
# @param username [String] # @param username [String]
# @return [Ebooks::Bot] # @return [Ebooks::Bot]
def self.get(username) def self.get(username)
all.find { |bot| bot.username == username } all.find { |bot| bot.username.downcase == username.downcase }
end end
# Logs info to stdout in the context of this bot # Logs info to stdout in the context of this bot