figure out the local type preference of the active candidate

mostly to find out if we're using turn/udp, turn/tcp or turn/tls. Will be useful for logging in #265.
This uses the same trick as the trickle-page to determine the local type preference, based on the comment in https://groups.google.com/d/msg/discuss-webrtc/NfCgW-8FhkE/3chOYjjPcboJ

It's probably in the wrong place and should be done in the completed event (which somehow I don't get?) but this should be enough to get the idea. Currently doesn't properly work for IPv6 (I think) since the local ip will have [] in the stats but not in the candidate line.

I'd still prefer getting the serverUrl in the candidate stats, but until then this hack allows gathering the data