Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
* @returns {string|number}
*/
getHttpsPort(): {address: string; port: number} {
return ServerSettingsService.buildAddressAndPort(this.map.get("httpsPort"));
}
/**
*
* @param settings
*/
setHttpsPort(settings: {address: string; port: number}) {
this.map.set("httpsPort", `${settings.address}:${settings.port}`);
}
}
registerFactory(ServerSettingsService);
* }
* ```
*
* > Note: TypeScript transform and store `HttpServer` as `Function` type in the metadata. So to inject a factory, you must use the `@Inject(type)` decorator.
*
* @param {Type} target
* @param {string} targetKey
* @param {TypedPropertyDescriptor | number} descriptor
* @returns {any}
* @decorator
*/
export function HttpServer(target: Type, targetKey: string, descriptor: TypedPropertyDescriptor | number) {
return Inject(HttpServer)(target, targetKey, descriptor);
}
registerFactory(HttpServer);