Fix `duration` param bug