Cut off your nose to spite your face

Generated image of a woman cutting off her nose
The idiom cut off your nose to spite your face means to do something that disadvantages yourself when you try and punish someone else. It is an act of self-sabotage to spite someone else.

She crashed her car on purpose so her boyfriend would stop borrowing it without asking. Didn't she cut off her nose to spite her face?