From 0cefa8d125fa92d5cb6b89ae3315b836ab945d10 Mon Sep 17 00:00:00 2001 From: Jake Howard Date: Sun, 31 Mar 2024 15:08:01 +0100 Subject: [PATCH] Use contentless FTS --- yamdl_playground/core/apps.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yamdl_playground/core/apps.py b/yamdl_playground/core/apps.py index 3c72d13..54314c8 100644 --- a/yamdl_playground/core/apps.py +++ b/yamdl_playground/core/apps.py @@ -20,7 +20,7 @@ class CoreConfig(AppConfig): # Django doesn't like running DB queries during app initialization warnings.filterwarnings("ignore", module="django.db", category=RuntimeWarning) with connection.cursor() as cursor: - cursor.execute("CREATE VIRTUAL TABLE search_index USING fts5(body);") + cursor.execute("CREATE VIRTUAL TABLE search_index USING fts5(body, content='');") post_save.connect(self.post_save, sender=Page) self.loaded = True