Hi Mary,
Thank you for this thought, that is a very good question. I would say that you might be right, let it cool with the lid off first, in a place where no more moisture or debris is likely to get in. then cap when it’s at room temperature.
With warmth,
Benna