mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-10-06 05:26:54 +08:00
fixed the fix
This commit is contained in:
parent
a93ba0027c
commit
20a73cafb0
1 changed files with 3 additions and 3 deletions
|
@ -1481,12 +1481,12 @@ function tagsEdit(){
|
|||
hideBackgroundLoader();
|
||||
let status = e.data.resultCode;
|
||||
if(status === 1){
|
||||
updateResultEditTagsPanelButtons();
|
||||
showNotification('Tag added',2000);
|
||||
dbSnapshot.tags.push({
|
||||
name: inputVal,
|
||||
id: e.data.id
|
||||
})
|
||||
updateResultEditTagsPanelButtons();
|
||||
updateSettingsPage();
|
||||
updateFilterTags();
|
||||
}else if(status === -1){
|
||||
|
@ -1501,13 +1501,13 @@ function tagsEdit(){
|
|||
hideBackgroundLoader();
|
||||
let status = e.data.resultCode;
|
||||
if(status === 1){
|
||||
updateResultEditTagsPanelButtons();
|
||||
showNotification('Tag updated',2000);
|
||||
dbSnapshot.tags.forEach(tag => {
|
||||
if(tag.id === tagid){
|
||||
tag.name = inputVal;
|
||||
}
|
||||
})
|
||||
updateResultEditTagsPanelButtons();
|
||||
updateSettingsPage();
|
||||
updateFilterTags();
|
||||
}else if(status === -1){
|
||||
|
@ -1522,13 +1522,13 @@ function tagsEdit(){
|
|||
hideBackgroundLoader();
|
||||
let status = e.data.resultCode;
|
||||
if(status === 1){
|
||||
updateResultEditTagsPanelButtons();
|
||||
showNotification('Tag removed',2000);
|
||||
dbSnapshot.tags.forEach((tag,index) => {
|
||||
if(tag.id === tagid){
|
||||
dbSnapshot.tags.splice(index, 1);
|
||||
}
|
||||
})
|
||||
updateResultEditTagsPanelButtons();
|
||||
updateSettingsPage();
|
||||
updateFilterTags();
|
||||
updateActiveTags();
|
||||
|
|
Loading…
Add table
Reference in a new issue