trim code