A bakery sells two types of cakes: a chocolate cake and a vanilla cake. The chocolate cake costs $12 each, while the vanilla cake costs $10 each. During a holiday sale, a customer bought a total of 10 cakes and spent $110. If the customer bought twice as many chocolate cakes as vanilla cakes, how many chocolate cakes did the customer buy?