Fix bug checking for https and multiple ports

Ticket:	#6543