Fix issues with database migration files