Call trim() on input string