Hmm, that's strange. The maximum current in the wires to the motor is given by the stall current of the motors, and for 25mm motors that's usually in the 1-4A range on 3S. 22 AWG wires should be fine carrying that continuously. Could it have been the motors themselves or the ESC getting hot and melting the insulation on the connected wires?

By the way, I recommend using RC silicone-insulated wires in bots. The insulation is rated for 200 degrees C and it's also tougher than PVC. The wires are made of very fine strands, which makes them soft and easy to route inside the bot. Hobbyking's UK warehouse seems to be the cheapest UK seller.