Skip to main content
assertPublicHttpUrl(url): Promise<string>
Defined in: src/Utils/link-preview.ts:84 Throws unless url is http(s) and every address its host resolves to is public. Link previews fetch URLs taken from message text and from the fetched page, so without this a preview can reach services on the local network.

Parameters

url

string

Returns

Promise<string> the first resolved address