fixed a bug in beat trimming