fix: (regression beta) error "save is not defined"

Massimo Melina committed Jun 24, 2024 at 15:35 UTC 5d07e52cd91d26c414cdc267e3326e8fe1efc9a6
1 file changed -1
plugins/download-counter/plugin.js
-1
@@ -34,7 +34,6 @@ exports.init = async api => {
34 return {
35 frontend_js: 'main.js',
36 frontend_css: 'style.css',
37 - unload: () => save.flush(), // we may have pending savings
37 middleware: ctx => () => { // callback = execute after other middlewares are done
38 if (ctx.status >= 300 || ctx.state.download_counter_ignore || ctx.state.considerAsGui || ctx.state.includesLastByte === false) return
39 if (!(ctx.state.vfsNode || api.getConfig('archives') && ctx.state.archive)) return