From 14f477a6330c9169145a7f8b2721d02e7517513b Mon Sep 17 00:00:00 2001 From: KernelDeimos Date: Tue, 29 Oct 2024 18:55:58 -0400 Subject: [PATCH] fix: Collector bug on undefined body --- src/gui/src/util/Collector.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/src/util/Collector.js b/src/gui/src/util/Collector.js index 44f6926e..b6a2e306 100644 --- a/src/gui/src/util/Collector.js +++ b/src/gui/src/util/Collector.js @@ -29,7 +29,7 @@ export default def(class Collector { async get (route) { return await this.fetch({ method: 'get', route }); } - async post (route, body) { + async post (route, body = {}) { if ( this.antiCSRF ) { body.anti_csrf = await this.antiCSRF.token(); }