fix seed errors and migration type_id column