Remove index for author.search_vector, which is never used

This commit is contained in:
Adeodato Simó 2023-11-24 14:15:00 -03:00
parent 0299f2e235
commit e4d688665c
No known key found for this signature in database
GPG key ID: CDF447845F1A986F
2 changed files with 16 additions and 6 deletions

View file

@ -0,0 +1,16 @@
# Generated by Django 3.2.20 on 2023-11-24 17:11
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
("bookwyrm", "0188_theme_loads"),
]
operations = [
migrations.RemoveIndex(
model_name="author",
name="bookwyrm_au_search__b050a8_gin",
),
]

View file

@ -2,7 +2,6 @@
import re
from typing import Tuple, Any
from django.contrib.postgres.indexes import GinIndex
from django.db import models
from bookwyrm import activitypub
@ -68,8 +67,3 @@ class Author(BookDataModel):
return f"https://{DOMAIN}/author/{self.id}"
activity_serializer = activitypub.Author
class Meta:
"""sets up postgres GIN index field"""
indexes = (GinIndex(fields=["search_vector"]),)