mirror of
https://github.com/nbd-wtf/go-nostr.git
synced 2025-08-31 08:11:35 +02:00
sdk: I am crazy and had removed the actual cache.Set() calls.
This commit is contained in:
@@ -61,6 +61,7 @@ func fetchGenericList[I TagItemWithValue](
|
|||||||
items := parseItemsFromEventTags(events[0], parseTag)
|
items := parseItemsFromEventTags(events[0], parseTag)
|
||||||
v.Event = events[0]
|
v.Event = events[0]
|
||||||
v.Items = items
|
v.Items = items
|
||||||
|
cache.SetWithTTL(pubkey, v, time.Hour*6)
|
||||||
valueWasJustCached[lockIdx] = true
|
valueWasJustCached[lockIdx] = true
|
||||||
return v, true
|
return v, true
|
||||||
}
|
}
|
||||||
@@ -73,6 +74,7 @@ func fetchGenericList[I TagItemWithValue](
|
|||||||
v.Items = items
|
v.Items = items
|
||||||
sys.StoreRelay.Publish(ctx, *evt)
|
sys.StoreRelay.Publish(ctx, *evt)
|
||||||
}
|
}
|
||||||
|
cache.SetWithTTL(pubkey, v, time.Hour*6)
|
||||||
valueWasJustCached[lockIdx] = true
|
valueWasJustCached[lockIdx] = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user