fixed bug that appears when no tls connections are present