01 -
Preheat your oven to 350°F (175°C) and grease and flour two 9-inch round cake pans.
02 -
In a large bowl, whisk together the flour, granulated sugar, brown sugar, baking powder, baking soda, salt, cinnamon, and nutmeg.
03 -
In another bowl, mix together the vegetable oil, eggs, mashed bananas, and crushed pineapple.
04 -
Gradually combine the wet ingredients with the dry ingredients, mixing until just combined. Fold in the chopped pecans if using.
05 -
Divide the batter evenly between the prepared pans and smooth the tops.
06 -
Bake for 25-30 minutes, or until a toothpick inserted into the center comes out clean. Let the cakes cool in the pans for 10 minutes, then transfer to a wire rack to cool completely.
07 -
For the cream cheese frosting: Beat the softened cream cheese and butter until smooth and creamy. Gradually add powdered sugar, beating well after each addition. Mix in vanilla extract.
08 -
Once the cakes are completely cooled, frost them with the cream cheese frosting. Slice and enjoy.