migration.scripts: add 6_emoji_require_colon_true

- schema: change default on guild_emoji.require_colons to true
This commit is contained in:
Luna Mendes 2018-11-20 17:10:34 -03:00
parent 6a085c2190
commit 05c8204271
2 changed files with 6 additions and 1 deletions

View File

@ -0,0 +1,5 @@
-- require_colons seems to be true for all custom emoji.
ALTER TABLE guild_emoji ALTER COLUMN require_colons SET DEFAULT true;
-- retroactively update all other emojis
UPDATE guild_emoji SET require_colons=true;

View File

@ -456,7 +456,7 @@ CREATE TABLE IF NOT EXISTS guild_emoji (
image text REFERENCES icons (hash),
animated bool DEFAULT false,
managed bool DEFAULT false,
require_colons bool DEFAULT false
require_colons bool DEFAULT true
);
/* Someday I might actually write this.