()
| 841 | } |
| 842 | |
| 843 | async function apiDelGlobalBak() { |
| 844 | const backup = $.toObj($request.body) |
| 845 | const backups = $.getjson($.KEY_backups, []) |
| 846 | const bakIdx = backups.findIndex((b) => b.id === backup.id) |
| 847 | if (bakIdx > -1) { |
| 848 | backups.splice(bakIdx, 1) |
| 849 | $.setdata('', backup.id) |
| 850 | $.setjson(backups, $.KEY_backups) |
| 851 | } |
| 852 | $.json = getBoxData() |
| 853 | } |
| 854 | |
| 855 | async function apiUpdateGlobalBak() { |
| 856 | const { id: backupId, name: backupName } = $.toObj($request.body) |
nothing calls this directly
no test coverage detected