Use ExposedPort.toString() in serialization

Found one more place where parsing and stringification could be improved. Same as the others before.