Of course, being on the Moon doing an EVA meant an astronaut couldn’t strip down to defecate in a bag. During lunar sojourns, the astronauts wore a fecal containment subsystem as part of the personal hygiene equipment. It was, in essence, a diaper. Similarly, spacewalking astronauts on shuttle missions and aboard the International Space Station can’t exactly strip down to go. So they wear what NASA calls the maximum absorbency garment, which is also basically a diaper. But astronauts try not to use it, preferring to use an actual toilet.