Strip trailing whitespace.
Prevent error which occurs if another library has extended the Array prototype.