Projectivity of the moduli space of stable curves