Extract `map toLower` into a function.