mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-12-29 14:21:34 +00:00
Nutomic
a00313e680
* Merge /site_inbox into /inbox (fixes #4137) Get rid of different inboxes, only use /inbox Remove shared_inbox_url db columns add code migration move to db migration, fixes machete fix sql drop inbox url unique constraints Dont create auth cookie in backend (#4136) dont change individual inboxes to shared inbox Dont send comment reply to user who has community blocked. Fixes #3684 (#4096) * Dont send comment reply to user who has community blocked. Fixes #3684 * Adding source instance block check. * Adding api test. * Addressing PR comments. * move site inbox rewrite to db * fix test * clippy * clippy 2 * fix test
30 lines
765 B
SQL
30 lines
765 B
SQL
-- drop unique constraints for inbox columns
|
|
ALTER TABLE person
|
|
DROP CONSTRAINT idx_person_inbox_url;
|
|
|
|
ALTER TABLE community
|
|
DROP CONSTRAINT idx_community_inbox_url;
|
|
|
|
-- change site inbox path from /inbox to /site_inbox
|
|
-- we dont have any way here to set the correct protocol (http or https) according to tls_enabled, or set
|
|
-- the correct port in case of debugging
|
|
UPDATE
|
|
site
|
|
SET
|
|
inbox_url = inbox_query.inbox
|
|
FROM (
|
|
SELECT
|
|
format('https://%s/inbox', DOMAIN) AS inbox
|
|
FROM
|
|
instance,
|
|
site,
|
|
local_site
|
|
WHERE
|
|
instance.id = site.instance_id
|
|
AND local_site.id = site.id) AS inbox_query,
|
|
instance,
|
|
local_site
|
|
WHERE
|
|
instance.id = site.instance_id
|
|
AND local_site.id = site.id;
|
|
|