fixing variable port