handle missing duration
don't mess up empty env