fix: bot stats to comply with strict null check

This commit is contained in:
abdou6666 2024-12-31 14:28:33 +01:00
parent 1683ce5ca0
commit ea438a45c1

View File

@ -55,7 +55,7 @@ export class BotStats extends BaseSchema {
*/ */
@Prop({ type: Number, default: 0 }) @Prop({ type: Number, default: 0 })
value?: number; value: number;
/** /**
* name of the insight (e.g: incoming messages). * name of the insight (e.g: incoming messages).
@ -76,7 +76,7 @@ export class BotStats extends BaseSchema {
id: index + 1, id: index + 1,
name: type, name: type,
values: [], values: [],
}; } as ToLinesType;
}); });
const index: { [dataName: string]: number } = data.reduce( const index: { [dataName: string]: number } = data.reduce(