fix canary crashing

This commit is contained in:
Vendicated 2023-12-21 23:41:12 +01:00
parent fdf3480b27
commit 686f2d925f
No known key found for this signature in database
GPG key ID: D66986BAF75ECF18
2 changed files with 3 additions and 2 deletions

View file

@ -45,8 +45,8 @@ export default definePlugin({
{
find: ".embedWrapper,embed",
replacement: [{
match: /\.embedWrapper/g,
replace: "$&+(this.props.channel.nsfw?' vc-nsfw-img':'')"
match: /\.embedWrapper(?=.+?channel_id:(\i)\.id)/g,
replace: "$&+($1.nsfw?' vc-nsfw-img':'')"
}]
}
],

View file

@ -328,6 +328,7 @@ export default definePlugin({
// Attachment renderer
// Module 96063
find: ".removeAttachmentHoverButton",
group: true,
replacement: [
{
match: /(className:\i,attachment:\i),/,