Ensure combined appenders respect product id too

This commit is contained in:
Logan Ramos 2021-07-16 09:31:01 -04:00
parent be26cf639c
commit 8ec61e8c86
No known key found for this signature in database
GPG key ID: D9CCFF14F0B18183

View file

@ -63,7 +63,8 @@ export interface ITelemetryAppender {
export function combinedAppender(...appenders: ITelemetryAppender[]): ITelemetryAppender {
return {
log: (e, d) => appenders.forEach(a => a.log(e, d)),
flush: () => Promises.settled(appenders.map(a => a.flush()))
flush: () => Promises.settled(appenders.map(a => a.flush())),
productIdentifier: appenders.find(a => a.productIdentifier !== undefined)?.productIdentifier
};
}