From eb2aba46eabc8d90656b760cf4900f56119de9ca Mon Sep 17 00:00:00 2001
From: Matthew Somerville <matthew-github@dracos.co.uk>
Date: Tue, 20 Nov 2018 16:40:53 +0000
Subject: Store all moderation change history in database.

Currently keeping the same front end functionality of only reverting to
the original.
---
 db/schema_0064-allow-multiple-moderations.sql | 8 ++++++++
 1 file changed, 8 insertions(+)
 create mode 100644 db/schema_0064-allow-multiple-moderations.sql

(limited to 'db/schema_0064-allow-multiple-moderations.sql')

diff --git a/db/schema_0064-allow-multiple-moderations.sql b/db/schema_0064-allow-multiple-moderations.sql
new file mode 100644
index 000000000..5fee96282
--- /dev/null
+++ b/db/schema_0064-allow-multiple-moderations.sql
@@ -0,0 +1,8 @@
+BEGIN;
+
+ALTER TABLE moderation_original_data
+    DROP CONSTRAINT moderation_original_data_comment_id_key;
+CREATE INDEX moderation_original_data_problem_id_comment_id_idx
+    ON moderation_original_data(problem_id, comment_id);
+
+COMMIT;
-- 
cgit v1.2.3

