Fixed corrupt db migration