fixed apply migrations