I can see why you all jumped to the conclusion it would be female-only from what you said, you all likely had other things on your mind than checking this. I think in the run up to the operation, someone should have asked her preference on the matter.
It's awful that your aunt has been so hurt by this. I hope you can all get the support you need.
A medical proffesional is a medical proffesional, they arent perverts getting of on seeing sick peoples vaginas. They trained hard and work hard to care for the vunerable thats all and their genitals have no part of that.
As someone who has been raped in hospital, when I was quite ill, I'd like to say such violence is about power, not really about getting off (mine laughed about how I'd been "taught a lesson"), and no matter how hard someone works for their qualification, it doesn't mean that they wouldn't abuse power. Going on about the work to get into a particular field like that makes any differences dismisses victims of abuse by people in those fields. That's become understood with clergy and teachers, but there still seems to be some barrier to some people getting that with medical professionals.
I don't think anything like that has happened with the OP's aunt, he most likely did his job okay, but there is a reason why procedures have been developed to check consent and why it's such an issue that things are so overstretched these days that too often they're ignored or done in a way that doesn't always demonstrate full understanding of the patient.
I know near me, places have put up big signs during COVID about the right to ask for a chaperone and similar and professionals have asked me, even the women. Pre-COVID, we were encouraged to bring our own in if that would make us more comfortable. There are systems in place that run well in some places, though some are shakier at the moment. There may have been some here that didn't take account enough how some vulnerable people act in these situations.
Whatever the reason, it doesn't change that a vulnerable woman was hurt in this situation & no amount of going on about what qualifications the person might have had or that medical professionals are not perverts changes that.