MCPcopy Index your code
hub / github.com/Flagsmith/flagsmith / clear_environment_cache

Method clear_environment_cache

api/environments/models.py:173–177  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

171
172 @hook(AFTER_UPDATE) # type: ignore[misc]
173 def clear_environment_cache(self) -> None:
174 # TODO: this could rebuild the cache itself (using an async task)
175 environment_cache.delete_many(
176 [self.initial_value("api_key"), *[eak.key for eak in self.api_keys.all()]]
177 )
178
179 @hook(AFTER_UPDATE, when="api_key", has_changed=True) # type: ignore[misc]
180 def update_environment_document_cache(self) -> None:

Callers

nothing calls this directly

Calls 1

allMethod · 0.45

Tested by

no test coverage detected