build fix
This commit is contained in:
1 parent
5784fec3d1
commit
af141ec772
1 file changed
+4
-1
@@ -12,7 +12,7 @@ class BufferService {
|
|||||||
private SERVICE_NAME: string;
|
private SERVICE_NAME: string;
|
||||||
private buffer: any[];
|
private buffer: any[];
|
||||||
private incidentBuffer: any[];
|
private incidentBuffer: any[];
|
||||||
private bufferTimer: NodeJS.Timeout;
|
private bufferTimer: NodeJS.Timeout | null = null;
|
||||||
private checksService: any;
|
private checksService: any;
|
||||||
|
|
||||||
constructor({
|
constructor({
|
||||||
@@ -122,6 +122,9 @@ class BufferService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
scheduleNextFlush() {
|
scheduleNextFlush() {
|
||||||
|
if (this.bufferTimer) {
|
||||||
|
clearTimeout(this.bufferTimer);
|
||||||
|
}
|
||||||
this.bufferTimer = setTimeout(async () => {
|
this.bufferTimer = setTimeout(async () => {
|
||||||
try {
|
try {
|
||||||
await this.flushBuffer();
|
await this.flushBuffer();
|
||||||
|
|||||||
Reference in new issue
Block a user