Eliminate case statement with a cool bit of ruby that allows passing of string or array to object method