MCPcopy
hub / github.com/chavyleung/scripts / apiDelGlobalBak

Function apiDelGlobalBak

chavy.box.js:788–798  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

786}
787
788async function apiDelGlobalBak() {
789 const backup = $.toObj($request.body)
790 const backups = $.getjson($.KEY_backups, [])
791 const bakIdx = backups.findIndex((b) => b.id === backup.id)
792 if (bakIdx > -1) {
793 backups.splice(bakIdx, 1)
794 $.setdata('', backup.id)
795 $.setjson(backups, $.KEY_backups)
796 }
797 $.json = getBoxData()
798}
799
800async function apiUpdateGlobalBak() {
801 const { id: backupId, name: backupName } = $.toObj($request.body)

Callers

nothing calls this directly

Calls 5

getBoxDataFunction · 0.70
toObjMethod · 0.45
getjsonMethod · 0.45
setdataMethod · 0.45
setjsonMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…