summary refs log tree commit diff
path: root/src/util
diff options
context:
space:
mode:
authorMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2023-04-11 13:47:26 +1000
committerMadeline <46743919+MaddyUnderStars@users.noreply.github.com>2023-04-11 13:47:26 +1000
commitab07ad692c837e5abe016cfb4a973d35d50c8d44 (patch)
tree2bbe8ab1417f9f00be03fc2baa53491424393f27 /src/util
parentUpdate reactions.ts (diff)
downloadserver-ab07ad692c837e5abe016cfb4a973d35d50c8d44.tar.xz
send public member in message_reaction_add eventt
Diffstat (limited to 'src/util')
-rw-r--r--src/util/entities/Member.ts9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/util/entities/Member.ts b/src/util/entities/Member.ts
index 13e74dcd..cd885c13 100644
--- a/src/util/entities/Member.ts
+++ b/src/util/entities/Member.ts
@@ -440,6 +440,15 @@ export class Member extends BaseClassWithoutId {
 			]);
 		}
 	}
+
+	toPublicMember() {
+		// eslint-disable-next-line @typescript-eslint/no-explicit-any
+		const member: any = {};
+		PublicMemberProjection.forEach((x) => {
+			member[x] = this[x];
+		});
+		return member as PublicMember;
+	}
 }
 
 export interface ChannelOverride {