MCPcopy
hub / github.com/nestjs/nest / getUrl

Method getUrl

packages/core/nest-application.ts:344–354  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

342 }
343
344 public async getUrl(): Promise<string> {
345 return new Promise((resolve, reject) => {
346 if (!this.isListening) {
347 this.logger.error(MESSAGES.CALL_LISTEN_FIRST);
348 reject(MESSAGES.CALL_LISTEN_FIRST);
349 return;
350 }
351 const address = this.httpServer.address();
352 resolve(this.formatAddress(address));
353 });
354 }
355
356 private formatAddress(address: any): string {
357 if (isString(address)) {

Callers

nothing calls this directly

Calls 2

formatAddressMethod · 0.95
errorMethod · 0.65

Tested by

no test coverage detected