Has your toddler ever taken off their sleepsack and pajamas so they're just sleeping in their diaper? What did you do?

My toddler has been taking off his sleepsack but today he took off his PJs too and fell asleep. I'm nervous he'll take off his diaper during the night but don't want to wake him and get him dressed as he'll freak out being woken up then left. Is there a hack so they can't get their PJs off?