Hi,
Grubs are a part of composting and most of them pose no problem. Depending on the type of grub you have you may not have to worry. The grub we know most commonly is the white grub that is about an inch long and is curls up in a "C" shape. the other grubs such as the green fruit fly is large, and doesn't curl up and the larva of the stag beetle which is very large and fat. In any case many are beneficial and if you are worried about the other ones that are not you could sift the compost and remove them or if they are the other kind just leave them alone