Modify port set logic