Method for monitoring the secondary drying in a freeze-drying process