Fix multiple calls to nextBeat