mirror of
https://github.com/matrix-org/dendrite.git
synced 2024-12-01 18:51:56 -06:00
Ignore duplicate redaction entries (#1522)
This commit is contained in:
parent
286dd408ae
commit
8d9ecb3996
|
@ -39,7 +39,8 @@ CREATE INDEX IF NOT EXISTS roomserver_redactions_redacts_event_id ON roomserver_
|
||||||
|
|
||||||
const insertRedactionSQL = "" +
|
const insertRedactionSQL = "" +
|
||||||
"INSERT INTO roomserver_redactions (redaction_event_id, redacts_event_id, validated)" +
|
"INSERT INTO roomserver_redactions (redaction_event_id, redacts_event_id, validated)" +
|
||||||
" VALUES ($1, $2, $3)"
|
" VALUES ($1, $2, $3)" +
|
||||||
|
" ON CONFLICT DO NOTHING"
|
||||||
|
|
||||||
const selectRedactionInfoByRedactionEventIDSQL = "" +
|
const selectRedactionInfoByRedactionEventIDSQL = "" +
|
||||||
"SELECT redaction_event_id, redacts_event_id, validated FROM roomserver_redactions" +
|
"SELECT redaction_event_id, redacts_event_id, validated FROM roomserver_redactions" +
|
||||||
|
|
|
@ -37,7 +37,7 @@ CREATE TABLE IF NOT EXISTS roomserver_redactions (
|
||||||
`
|
`
|
||||||
|
|
||||||
const insertRedactionSQL = "" +
|
const insertRedactionSQL = "" +
|
||||||
"INSERT INTO roomserver_redactions (redaction_event_id, redacts_event_id, validated)" +
|
"INSERT OR IGNORE INTO roomserver_redactions (redaction_event_id, redacts_event_id, validated)" +
|
||||||
" VALUES ($1, $2, $3)"
|
" VALUES ($1, $2, $3)"
|
||||||
|
|
||||||
const selectRedactionInfoByRedactionEventIDSQL = "" +
|
const selectRedactionInfoByRedactionEventIDSQL = "" +
|
||||||
|
|
Loading…
Reference in a new issue