discourse/plugins
Andrei Prigorshnev e83d8fb3e2
FIX: Allow several chat channels to have an empty slug (#25680)
In certain cases, chat channels may have empty slugs, it happens when:

1. The `slug_generation_method` setting is set to `None`
2. `slug_generation_method` is set to `ASCII` and a channel with 
a Unicode name and an empty slug is created (in this case, the code 
that creates channels tries to generate a slug and fallbacks to an empty slug)

At the moment, we have a unique index on the `chat_channels.slug` column 
which leads to errors when creating several channels with empty slugs 
(Discourse is able to create one such channel, but when trying to create 
the second one fails because of the unique constraint). This PR fixes that 
by adding a `where` condition to the index. Slugs still have to be unique, 
but now many channels may have empty slugs.

This fix is similar to the one we made to the category slugs – 7ba914f1e1.
2024-02-15 00:39:39 +04:00
..
chat FIX: Allow several chat channels to have an empty slug (#25680) 2024-02-15 00:39:39 +04:00
checklist DEV: Use `service:` lookups instead of `:main` (#25402) 2024-01-24 15:59:44 +01:00
discourse-details Update translations (#25659) 2024-02-13 16:11:30 +01:00
discourse-lazy-videos DEV: Use `service:` lookups instead of `:main` (#25402) 2024-01-24 15:59:44 +01:00
discourse-local-dates PERF: eliminate some slow CSS selectors (#25392) 2024-01-26 13:10:45 -05:00
discourse-narrative-bot Update translations (#25579) 2024-02-06 22:35:44 +01:00
discourse-presence DEV: Convert min_trust_to_edit_wiki_post to groups (#24766) 2023-12-12 15:20:37 +11:00
footnote DEV: Use `service:` lookups instead of `:main` (#25402) 2024-01-24 15:59:44 +01:00
poll Update translations (#25659) 2024-02-13 16:11:30 +01:00
spoiler-alert DEV: Use `service:` lookups instead of `:main` (#25402) 2024-01-24 15:59:44 +01:00
styleguide Update translations (#25659) 2024-02-13 16:11:30 +01:00