From 2d40d39264de4eed0bdb9e8e0117a8c1e2f199d3 Mon Sep 17 00:00:00 2001
From: ilotterytea <iltsu@alright.party>
Date: Fri, 13 Dec 2024 23:50:45 +0500
Subject: feat: now you can listen to github

---
 migrations/2024-12-13T21-55-38_github_support/up.sql | 6 ++++++
 1 file changed, 6 insertions(+)
 create mode 100644 migrations/2024-12-13T21-55-38_github_support/up.sql

(limited to 'migrations/2024-12-13T21-55-38_github_support/up.sql')

diff --git a/migrations/2024-12-13T21-55-38_github_support/up.sql b/migrations/2024-12-13T21-55-38_github_support/up.sql
new file mode 100644
index 0000000..666d774
--- /dev/null
+++ b/migrations/2024-12-13T21-55-38_github_support/up.sql
@@ -0,0 +1,6 @@
+-- Your SQL goes here
+ALTER TABLE "events" DROP CONSTRAINT check_event_type;
+ALTER TABLE "events" ADD CONSTRAINT check_event_type CHECK (
+    ("target_alias_id" IS NOT NULL AND "event_type" < 10)
+    OR ("custom_alias_id" IS NOT NULL AND "event_type" >= 10)
+);
\ No newline at end of file
-- 
cgit v1.2.3

