They are typically just written out of the conflict. In this case I assume that you are talking about Captain Marvel whom I believe is always needed on other planets in other galaxies except for the rare occassion when the writers needs a deus ex machina.