I did that to a carbon XO mech on a demo bike…luckily the shop accepted the gears had been poorly adjusted. Didn't help me though, had to walk back to the carpark as although we had a spare hanger, the threads of the mech ripped partway out of the hanger meaning none of us could unbolt it and install a spare. Even at home with a vise and long allen keys I couldn't budge the bolt, I gave up as the bolt showed signs of rounding off and returned the bike to the shop with the offer of a replacement hanger. They gracefully declined though. Apparently the bike was off the trails for a good few weeks 😯