MCPcopy Index your code
hub / github.com/HelloZeroNet/ZeroNet / addCachedKey

Method addCachedKey

src/Content/ContentDbDict.py:50–52  ·  view source on GitHub ↗
(self, key)

Source from the content-addressed store, hash-verified

48 dict.__setitem__(self, key_deleted, False)
49
50 def addCachedKey(self, key):
51 if key not in self.cached_keys and key != "content.json" and len(key) > 40: # Always keep keys smaller than 40 char
52 self.cached_keys.append(key)
53
54 def __getitem__(self, key):
55 val = dict.get(self, key)

Callers 2

loadItemMethod · 0.95
__setitem__Method · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected