(url: string, config: Config)
| 706 | * @returns The full URL object |
| 707 | */ |
| 708 | export const convertPathToURL = (url: string, config: Config): URL => { |
| 709 | const external = config.getExternalAddress(); |
| 710 | const fullInboundURL = new URL(url, external).href; |
| 711 | const internalPath = fullInboundURL.replace(external, ''); |
| 712 | |
| 713 | return new URL(internalPath, config.getServerAddress()); |
| 714 | }; |
| 715 | |
| 716 | export const makeExternalURL = ( |
| 717 | externalAddress: string, |
no test coverage detected