*Skip cache update if error is ERR_NOT_READY

This commit is contained in:
Derrick Hammer 2022-07-23 02:49:02 -04:00
parent a4ddcdf518
commit 830aa19a4f
1 changed files with 4 additions and 1 deletions

View File

@ -134,7 +134,10 @@ async function processRequest(request: RPCRequest): Promise<RPCResponse> {
? { error }
: (rpcResp as unknown as JSONRPCResponseWithResult).result;
if (!processedRequests.get(reqId) || request.force) {
if (
(!processedRequests.get(reqId) || request.force) &&
dbData.data?.error !== ERR_NOT_READY
) {
processedRequests.set(reqId, dbData);
}