(value: number | undefined)
| 48 | } |
| 49 | |
| 50 | function normalizePort(value: number | undefined): number | undefined { |
| 51 | if (!Number.isInteger(value)) return undefined; |
| 52 | if ((value as number) <= 0 || (value as number) > 65_535) return undefined; |
| 53 | return value; |
| 54 | } |
| 55 | |
| 56 | function defaultPortForProtocol(protocol: string): number | undefined { |
| 57 | if (protocol === 'https:') return 443; |
no outgoing calls
no test coverage detected