minor fixes with the migration script