remove junk at end