On the outside, a cake may appear to be cooked, but when you slice through the centre of the cake, sometimes the interior is still soggy and underbaked. Your cake is not lost. There are ways to salvage your underdone cake for serving. Keep in mind the type of cake you are making. Lava cakes and pudding cakes are designed to have a molten centre and should not be cooked completely, but for most other cakes, you will need to return the cake to the oven after some slight changes.
Preheat the oven to 163 degrees Celsius.
Place the cake on a baking tray and cover the cake with aluminium foil.
Transfer the cake on the baking tray to the oven. Turn off the oven.
Residual heat from the oven will continue to slowly bake the cake without burning it.
Remove the cake after 10 to 15 minutes.
Insert a toothpick into the centre of the cake. If if comes out clean, the cake is cooked through.
Scoop out the centre of the cake with an ice cream scoop if it is still underdone and soggy or sunken.
Fill the centre of the cake with berries or frost around the scooped-out portion as though frosting a tube cake.