(url: string)
| 48 | } |
| 49 | |
| 50 | function sanitizeToolUrl(url: string): string { |
| 51 | try { |
| 52 | const protocol = new URL(url).protocol; |
| 53 | if ( |
| 54 | protocol === "http:" || |
| 55 | protocol === "https:" || |
| 56 | protocol === "vscode:" || |
| 57 | protocol === "vscode-insiders:" |
| 58 | ) { |
| 59 | return escapeHtml(url); |
| 60 | } |
| 61 | } catch { |
| 62 | return "#"; |
| 63 | } |
| 64 | |
| 65 | return "#"; |
| 66 | } |
| 67 | |
| 68 | function getToolActionLink( |
| 69 | href: string | undefined, |
no test coverage detected