Proper trailing spaces removal