aboutsummaryrefslogtreecommitdiff
path: root/src/plugins/pinDms
diff options
context:
space:
mode:
authorNuckyz <61953774+Nuckyz@users.noreply.github.com>2023-04-14 21:47:03 -0300
committerGitHub <noreply@github.com>2023-04-15 02:47:03 +0200
commit96f640da674e89824881070c4081b7aee212e619 (patch)
tree9d8dbdf97313c79410c8d1a2b380116d2b7d3a86 /src/plugins/pinDms
parente8809fc57bd1c679e9a84ae6adc949655e3a86ec (diff)
downloadVencord-96f640da674e89824881070c4081b7aee212e619.tar.gz
Vencord-96f640da674e89824881070c4081b7aee212e619.tar.bz2
Vencord-96f640da674e89824881070c4081b7aee212e619.zip
Make Context Menu API support hooks (#902)
Co-authored-by: V <vendicated@riseup.net>
Diffstat (limited to 'src/plugins/pinDms')
-rw-r--r--src/plugins/pinDms/contextMenus.tsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/pinDms/contextMenus.tsx b/src/plugins/pinDms/contextMenus.tsx
index b04ba8c..d75c9f9 100644
--- a/src/plugins/pinDms/contextMenus.tsx
+++ b/src/plugins/pinDms/contextMenus.tsx
@@ -49,13 +49,13 @@ function PinMenuItem(channelId: string) {
);
}
-const GroupDMContext: NavContextMenuPatchCallback = (children, props) => {
+const GroupDMContext: NavContextMenuPatchCallback = (children, props) => () => {
const container = findGroupChildrenByChildId("leave-channel", children);
if (container)
container.unshift(PinMenuItem(props.channel.id));
};
-const UserContext: NavContextMenuPatchCallback = (children, props) => {
+const UserContext: NavContextMenuPatchCallback = (children, props) => () => {
const container = findGroupChildrenByChildId("close-dm", children);
if (container) {
const idx = container.findIndex(c => c?.props?.id === "close-dm");