From 896d3672f406bfe90bd9682591da01ba7d1501c0 Mon Sep 17 00:00:00 2001 From: ImAaronFR <96433859+ImAaronFR@users.noreply.github.com> Date: Tue, 8 Feb 2022 08:44:07 +0330 Subject: [Fix] Column "groups" contains null-values (#622) --- util/src/entities/Emoji.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'util/src') diff --git a/util/src/entities/Emoji.ts b/util/src/entities/Emoji.ts index 32d39234..a3615b7d 100644 --- a/util/src/entities/Emoji.ts +++ b/util/src/entities/Emoji.ts @@ -41,6 +41,6 @@ export class Emoji extends BaseClass { @Column({ type: "simple-array" }) roles: string[]; // roles this emoji is whitelisted to (new discord feature?) - @Column({ type: "simple-array" }) + @Column({ type: "simple-array", nullable: true }) groups: string[]; // user groups this emoji is whitelisted to (Fosscord extension) } -- cgit 1.5.1 From 3e0d2db0cb1e362b78b91eac79b11802988fb4de Mon Sep 17 00:00:00 2001 From: Erkin Alp Güney Date: Thu, 10 Feb 2022 21:14:48 +0300 Subject: Add more rights (#541) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Erkin Alp Güney * Added the backfilling-related rights * Added kick/ban rights * Added the presence right * Guild directory * Interactions rights --- util/src/util/Rights.ts | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'util/src') diff --git a/util/src/util/Rights.ts b/util/src/util/Rights.ts index f0d00baf..9a99d393 100644 --- a/util/src/util/Rights.ts +++ b/util/src/util/Rights.ts @@ -35,9 +35,9 @@ export class Rights extends BitField { ADD_MEMBERS: BitFlag(8), // can manually add any members in their guilds BYPASS_RATE_LIMITS: BitFlag(9), CREATE_APPLICATIONS: BitFlag(10), - CREATE_CHANNELS: BitFlag(11), + CREATE_CHANNELS: BitFlag(11), // can create guild channels or threads in the guilds that they have permission CREATE_DMS: BitFlag(12), - CREATE_DM_GROUPS: BitFlag(13), + CREATE_DM_GROUPS: BitFlag(13), // can create group DMs or custom orphan channels CREATE_GUILDS: BitFlag(14), CREATE_INVITES: BitFlag(15), // can create mass invites in the guilds that they have CREATE_INSTANT_INVITE CREATE_ROLES: BitFlag(16), @@ -57,6 +57,17 @@ export class Rights extends BitField { SELF_DELETE_DISABLE: BitFlag(30), // can disable/delete own account DEBTABLE: BitFlag(31), // can use pay-to-use features CREDITABLE: BitFlag(32), // can receive money from monetisation related features + KICK_BAN_MEMBERS: BitFlag(33), + // can kick or ban guild or group DM members in the guilds/groups that they have KICK_MEMBERS, or BAN_MEMBERS + SELF_LEAVE_GROUPS: BitFlag(34), + // can leave the guilds or group DMs that they joined on their own (one can always leave a guild or group DMs they have been force-added) + PRESENCE: BitFlag(35), + // inverts the presence confidentiality default (OPERATOR's presence is not routed by default, others' are) for a given user + SELF_ADD_DISCOVERABLE: BitFlag(36), // can mark discoverable guilds that they have permissions to mark as discoverable + MANAGE_GUILD_DIRECTORY: BitFlag(37), // can change anything in the primary guild directory + INITIATE_INTERACTIONS: BitFlag(40), // can initiate interactions + RESPOND_TO_INTERACTIONS: BitFlag(41), // can respond to interactions + SEND_BACKDATED_EVENTS: BitFlag(42), // can send backdated events }; any(permission: RightResolvable, checkOperator = true) { -- cgit 1.5.1 From c38d147a91025f6852429f9190fa64501b648d25 Mon Sep 17 00:00:00 2001 From: RealMANI <96433859+ImAaronFR@users.noreply.github.com> Date: Fri, 11 Feb 2022 08:43:46 +0330 Subject: Appropriate DB charset (#629) causes bugs like turning emojis to "????" --- util/src/util/Database.ts | 1 + 1 file changed, 1 insertion(+) (limited to 'util/src') diff --git a/util/src/util/Database.ts b/util/src/util/Database.ts index e8177093..9ab5d14c 100644 --- a/util/src/util/Database.ts +++ b/util/src/util/Database.ts @@ -25,6 +25,7 @@ export function initDatabase(): Promise { // @ts-ignore promise = createConnection({ type, + charset: 'utf8mb4', url: isSqlite ? undefined : dbConnectionString, database: isSqlite ? dbConnectionString : undefined, // @ts-ignore -- cgit 1.5.1