Rework migrations