From 9f00d8fec80d05592974d28c557117419027d21e Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Fri, 15 Sep 2023 22:10:36 -0400 Subject: [PATCH] fix: IStore should extend EventEmitter --- src/interfaces.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/interfaces.ts b/src/interfaces.ts index 06b326c..69959f7 100644 --- a/src/interfaces.ts +++ b/src/interfaces.ts @@ -2,6 +2,7 @@ import { BeaconConfig } from "@lodestar/config"; import { GenesisData, LightClientUpdate } from "#types.js"; import { ProverRequestCallback } from "#client/index.js"; import BaseClient from "#baseClient.js"; +import { EventEmitter } from "events"; export interface IProver { get callback(): ProverRequestCallback; @@ -12,7 +13,7 @@ export interface IProver { ): Promise; } -export interface IStore { +export interface IStore extends EventEmitter { addUpdate(period: number, update: LightClientUpdate): void; getUpdate(period: number): Uint8Array; hasUpdate(period: number): boolean;