Skip to content

Commit

Permalink
Merge branch '992-relayer' of github.com:warden-protocol/wardenprotoc…
Browse files Browse the repository at this point in the history
…ol into 992-relayer
  • Loading branch information
backsapc committed Nov 6, 2024
2 parents 2e61d55 + 11b7472 commit ab4716f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export class WardenClient {
}

async *pollSignatureRequests(): AsyncGenerator<INewSignatureRequest> {
let nextKey: Uint8Array | undefined = new Uint8Array();
let nextKey: Uint8Array | undefined = undefined;

while (true) {
await delay(this.configuration.pollingIntervalMsec);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,10 @@ export class LruCache<T> {
}

private refresh(key: string) {
const entry = this.values.get(key)!;
const entry = this.values.get(key);
if (entry === undefined) {
throw new Error(`Key ${key} not found in cache`);
}
this.values.delete(key);
this.values.set(key, entry);
return entry;
Expand Down

0 comments on commit ab4716f

Please sign in to comment.