Interestingly, Electric Shock Therapy is not the same as what is shown in One Flew Over the Cuckoo's Nest. It's used as a last resort for intractable depression or when it's dangerous to wait until medication kicks in.
There's a strict protocol involved before using ECT and the benefits have to outweigh the risks. It's not clear why it works and there is some controversy over how effective it really is.
Aversion therapy is used to change behavior and for the most part, considered an ineffectual and unethical form of therapy. ECT is a medical procedure which changes something in the brain, but it's not well understood how it works.
This article explains this better.
In some places in the world including where I am, shock treatment is being far overused for all kinds of things.
I know of several personality who have had shock treatment here and it was a bad error in except one who it did help (she had psychosis and was getting hallucinations with that eg seeing it snowing in the middle of summer)..
One they gave it to had behaviour issues (she's an adult with the mind of an 8 year old).. it hasnt helped her behaviour, she ended up in prison for biting her carer (she was schizophrenic too, when she got brought in she was having halluncinations of giant mosquitos and screaming in fear of these.. crazy they send people like that to prison in my state as they dont have room in the mental hopsital).,
another I knew has Aspergers and they mistook his aspersgers with a depressed state (which actually he didnt even have depression and him keeping to himself and not going out much etc was just part of his Aspergers). For him this shock treatment did him major damage, he was very into his studies etc and its left him still many years later with memory issues to the point he could no longer study well.
I even had one dr with my ME/CFS problems and what im going through, offer shock therapy to me (that happened when i was in prison). I did have depression but its just situational depression. Thankfully I didnt get that dr again.
Its scary that they are throwing around shock therapy here in the way they are and those who have this are given it multiple times. Even the psychotic the only one it helped, she had to have all these treatments done again years later as her problems came back. I think they were giving her 12 or 15 treatments a round of it (I cant remember the exact numbers but it was a very high number of sessions they gave).
Even after it when it was deemed successful as she wasnt having the intense hallunciations she previously was, it hadnt fixed her enough to be living without ongoing care support but yeah it did help her though by taking her from being a lot crazy to just a little crazy.
I did know 4 who went through this (and it only helped 1 out of the 4) but I cant think right now of the 4th persons situation or even who it was but I do remember that person had been left with memory issues after too.