@ywwg this block is dead code since duration is always non-NULL. Do you know what this did or is it vestigial?