Skip to content

Commit

Permalink
feat: improve the regex
Browse files Browse the repository at this point in the history
  • Loading branch information
rxri committed Dec 7, 2023
1 parent 24a3f7e commit 849943b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/preprocess/preprocess.go
Original file line number Diff line number Diff line change
Expand Up @@ -475,8 +475,8 @@ if (${1}.popper?.firstChild?.id === "context-menu") {

utils.Replace(
&input,
`(this\.updater)\s*=\s*(.*)`,
`${1}=Spicetify.Snackbar.updater=${2}`)
`(function\s*\w+\(.*\)\s*\{.*,\s*)(this\.updater\s*=\s*)(.*;)(.*\})`,
`${1}${2}Spicetify.Snackbar.updater=${3}${4}`)

return input
}
Expand Down

0 comments on commit 849943b

Please sign in to comment.