Merge remote-tracking branch 'upstream/dev' into dev
This commit is contained in:
commit
fedaed27b4
3 changed files with 13 additions and 5 deletions
|
|
@ -27,7 +27,7 @@ export default definePlugin({
|
|||
{
|
||||
find: "#{intl::MESSAGE_UTILITIES_A11Y_LABEL}",
|
||||
replacement: {
|
||||
match: /(?<=:null),(.{0,40}togglePopout:.+?}\)),(.+?)\]}\):null,(?<=\((\i\.\i),{label:.+?children:\[(\i&&!\i)\?\(0,\i\.jsxs?\)\(\i\.Fragment.+?message:(\i).+?)/,
|
||||
match: /(?<=:null),(.{0,40}togglePopout:.+?}\)),(.+?)\]}\):null,(?<=\((\i\.\i),{label:.+?:null,(\i)\?\(0,\i\.jsxs?\)\(\i\.Fragment.+?message:(\i).+?)/,
|
||||
replace: (_, ReactButton, PotionButton, ButtonComponent, showReactButton, message) => "" +
|
||||
`]}):null,Vencord.Api.MessagePopover._buildPopoverElements(${ButtonComponent},${message}),${showReactButton}?${ReactButton}:null,${showReactButton}&&${PotionButton},`
|
||||
}
|
||||
|
|
|
|||
|
|
@ -103,11 +103,19 @@ export default definePlugin({
|
|||
},
|
||||
// Fix some tricky experiments name causing a client crash
|
||||
{
|
||||
match: /\i\.\i\)\(\)(?<=(\i)=.+?).+?if\(null==(\i)(?=\);)/,
|
||||
replace: "$&||!Object.hasOwn($1,$2)"
|
||||
match: /.getExperimentBucketName.+?if\(null==(\i)\|\|null==\i(?=\)return null;)/,
|
||||
replace: "$&||({})[$1]!=null"
|
||||
}
|
||||
]
|
||||
},
|
||||
// Fix another function which cases crashes with tricky experiment names and the experiment embed
|
||||
{
|
||||
find: "}getServerAssignment(",
|
||||
replacement: {
|
||||
match: /}getServerAssignment\((\i),\i,\i\){/,
|
||||
replace: "$&if($1==null)return;"
|
||||
}
|
||||
}
|
||||
],
|
||||
|
||||
start: () => !BugReporterExperiment.getCurrentConfig().hasBugReporterAccess && enableStyle(hideBugReport),
|
||||
|
|
|
|||
|
|
@ -36,11 +36,11 @@ export default definePlugin({
|
|||
find: "getDefaultLayout(){",
|
||||
replacement: [
|
||||
{
|
||||
match: /getDefaultLayout\(\){/,
|
||||
match: /}getDefaultLayout\(\){/,
|
||||
replace: "$&return $self.getLayout();"
|
||||
},
|
||||
{
|
||||
match: /getDefaultSortOrder\(\){/,
|
||||
match: /}getDefaultSortOrder\(\){/,
|
||||
replace: "$&return $self.getSortOrder();"
|
||||
}
|
||||
]
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue