better detection for outbound links

better detection for outbound links