made the add-on type case insensitive

This commit is contained in:
Gunter Labes 2009-05-24 02:00:49 +00:00
parent 9622d9214e
commit e552237a2f

View file

@ -53,8 +53,9 @@ bool check_names_legal(const config& dir)
return true;
}
ADDON_TYPE get_addon_type(const std::string& str)
ADDON_TYPE get_addon_type(const std::string& type)
{
std::string str = utils::lowercase(type);
if (str.empty())
return ADDON_UNKNOWN;
else if (str == "campaign")