fix: remove analytics from SplitLogger (#9087)

Signed-off-by: Alexander Onnikov <Alexander.Onnikov@xored.com>
This commit is contained in:
Alexander Onnikov 2025-05-25 16:19:42 +07:00 committed by GitHub
parent 5aef4170c9
commit a5930052ef
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,7 +1,6 @@
//
// Copyright © 2024 Hardcore Engineering Inc.
//
import { Analytics } from '@hcengineering/analytics'
import { MeasureLogger, ParamsType } from '@hcengineering/core'
import { basename, dirname, join } from 'path'
import winston from 'winston'
@ -79,13 +78,6 @@ export class SplitLogger implements MeasureLogger {
}
error (message: string, obj?: Record<string, any>): void {
// Check if obj has error inside, so we could send it to Analytics
for (const v of Object.values(obj ?? {})) {
if (v instanceof Error) {
Analytics.handleError(v)
}
}
if (this.opts.parent !== undefined) {
this.opts.parent.error({ message, ...obj })
}