diff options
| author | feld <feld@feld.me> | 2021-02-08 16:43:04 +0000 |
|---|---|---|
| committer | feld <feld@feld.me> | 2021-02-08 16:43:04 +0000 |
| commit | 85cb122986087062a192c31bc517f2698239819c (patch) | |
| tree | 9f94d0bbf7bf8f68c272b43a779e49a4892e55b6 /priv | |
| parent | 4dbb08a19f57e720e299608ebeb4387d37c55e99 (diff) | |
| parent | 8babd796da46975c2d976cf87dad844c13e8a69e (diff) | |
| download | pleroma-85cb122986087062a192c31bc517f2698239819c.tar.gz pleroma-85cb122986087062a192c31bc517f2698239819c.zip | |
Merge branch 'develop' into 'docs/improve-mailer-settings-desc'
# Conflicts:
# CHANGELOG.md
Diffstat (limited to 'priv')
| -rw-r--r-- | priv/repo/migrations/20210121080964_add_default_text_search_config.exs | 11 | ||||
| -rw-r--r-- | priv/repo/optional_migrations/rum_indexing/20190510135645_add_fts_index_to_objects_two.exs | 2 |
2 files changed, 12 insertions, 1 deletions
diff --git a/priv/repo/migrations/20210121080964_add_default_text_search_config.exs b/priv/repo/migrations/20210121080964_add_default_text_search_config.exs new file mode 100644 index 000000000..09b6cccc9 --- /dev/null +++ b/priv/repo/migrations/20210121080964_add_default_text_search_config.exs @@ -0,0 +1,11 @@ +defmodule Pleroma.Repo.Migrations.AddDefaultTextSearchConfig do + use Ecto.Migration + + def change do + execute("DO $$ + BEGIN + execute 'ALTER DATABASE '||current_database()||' SET default_text_search_config = ''english'' '; + END + $$;") + end +end diff --git a/priv/repo/optional_migrations/rum_indexing/20190510135645_add_fts_index_to_objects_two.exs b/priv/repo/optional_migrations/rum_indexing/20190510135645_add_fts_index_to_objects_two.exs index 82e02281d..88476fb57 100644 --- a/priv/repo/optional_migrations/rum_indexing/20190510135645_add_fts_index_to_objects_two.exs +++ b/priv/repo/optional_migrations/rum_indexing/20190510135645_add_fts_index_to_objects_two.exs @@ -17,7 +17,7 @@ defmodule Pleroma.Repo.Migrations.AddFtsIndexToObjectsTwo do execute("CREATE FUNCTION objects_fts_update() RETURNS trigger AS $$ begin - new.fts_content := to_tsvector('english', new.data->>'content'); + new.fts_content := to_tsvector(new.data->>'content'); return new; end $$ LANGUAGE plpgsql") |
