simplify search code, make it case insensitive