Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

caching: Make sender type optional for flush_cache.

PIG208c4179428aca8
diff --git a/zerver/apps.py b/zerver/apps.py
index 587eb084030..19530d9f170 100644
--- a/zerver/apps.py
+++ b/zerver/apps.py
@@ -1,5 +1,5 @@
import logging
-from typing import Any
+from typing import Any, Optional
from django.apps import AppConfig
from django.conf import settings
@@ -7,7 +7,7 @@ from django.core.cache import cache
from django.db.models.signals import post_migrate
-def flush_cache(sender: AppConfig, **kwargs: Any) -> None:
+def flush_cache(sender: Optional[AppConfig], **kwargs: Any) -> None:
logging.info("Clearing memcached cache after migrations")
cache.clear()