From c1cd7ca64f9a9f17f35a9eab4f4df27521966fde Mon Sep 17 00:00:00 2001 From: Peter Pfeufer Date: Sat, 9 Aug 2025 10:36:22 +0200 Subject: [PATCH] [CHANGE] To `async` --- .../static/allianceauth/framework/js/auth-framework.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/allianceauth/framework/static/allianceauth/framework/js/auth-framework.js b/allianceauth/framework/static/allianceauth/framework/js/auth-framework.js index b9e06391..700ea200 100644 --- a/allianceauth/framework/static/allianceauth/framework/js/auth-framework.js +++ b/allianceauth/framework/static/allianceauth/framework/js/auth-framework.js @@ -160,12 +160,12 @@ const _fetchAjaxData = async ({ * @param {boolean} responseIsJson Whether the response is expected to be JSON or not (default: true) * @return {Promise} The fetched data */ -const fetchGet = ({ +const fetchGet = async ({ url, payload = null, responseIsJson = true }) => { - return _fetchAjaxData({ + return await _fetchAjaxData({ url: url, method: 'get', payload: payload, @@ -203,13 +203,13 @@ const fetchGet = ({ * @param {boolean} responseIsJson Whether the response is expected to be JSON or not (default: true) * @return {Promise} The fetched data */ -const fetchPost = ({ +const fetchPost = async ({ url, csrfToken, payload = null, responseIsJson = true }) => { - return _fetchAjaxData({ + return await _fetchAjaxData({ url: url, method: 'post', csrfToken: csrfToken,