From 9a431d98406f0edcb4e1ebddad0cb8e81deb536a Mon Sep 17 00:00:00 2001 From: evgeniy-scherbina Date: Tue, 17 Oct 2023 12:57:15 -0400 Subject: [PATCH] Added comments --- service/cachemdw/cache.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/service/cachemdw/cache.go b/service/cachemdw/cache.go index ef25f25..ce26e82 100644 --- a/service/cachemdw/cache.go +++ b/service/cachemdw/cache.go @@ -57,10 +57,13 @@ func IsCacheable( return false } + // blockNumber <= 0 means magic tag was used, one of the "latest", "pending", "earliest", etc... + // as of now we don't cache requests with magic tags if blockNumber <= 0 { return false } + // block number is specified and it's not a magic tag - cache the request return true }