Fixed suffix register error on config reload
This commit is contained in:
@@ -137,8 +137,6 @@ A big thanks to all our sponsors! Without them, it wouldn't be possible to creat
|
|||||||
|🇸🇪 Swedish |iamnotmega |🟠 Temporary Outdated (beta) |
|
|🇸🇪 Swedish |iamnotmega |🟠 Temporary Outdated (beta) |
|
||||||
|🇻🇳 Vietnamese |iamnotmega |🟠 Temporary Outdated (beta) |
|
|🇻🇳 Vietnamese |iamnotmega |🟠 Temporary Outdated (beta) |
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## ⭐️ Star History
|
## ⭐️ Star History
|
||||||
Please help us grow by giving a star! It would help us a lot!
|
Please help us grow by giving a star! It would help us a lot!
|
||||||
|
|
||||||
|
|||||||
@@ -18,8 +18,9 @@ export const loadAllOptions = async () => {
|
|||||||
|
|
||||||
//update options on config reload
|
//update options on config reload
|
||||||
optionConfig.onReload(async () => {
|
optionConfig.onReload(async () => {
|
||||||
//clear previous options
|
//clear previous options & suffixes
|
||||||
openticket.options.forEach((data,id) => {openticket.options.remove(id)})
|
openticket.options.forEach((data,id) => {openticket.options.remove(id)})
|
||||||
|
openticket.options.suffix.forEach((data,id) => {openticket.options.suffix.remove(id)})
|
||||||
|
|
||||||
//add new options
|
//add new options
|
||||||
optionConfig.data.forEach((option) => {
|
optionConfig.data.forEach((option) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user