From 0a9587901ab61fb217f621ad0eb9b708df361423 Mon Sep 17 00:00:00 2001 From: Yaodong Yu <2814461814@qq.com> Date: Mon, 24 Jul 2023 20:09:09 +0800 Subject: [PATCH] fix: fix response data assignment error in ApplicationEditPage.js (#2126) --- web/src/ApplicationEditPage.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/src/ApplicationEditPage.js b/web/src/ApplicationEditPage.js index 13df7643..d80fef1d 100644 --- a/web/src/ApplicationEditPage.js +++ b/web/src/ApplicationEditPage.js @@ -149,13 +149,13 @@ class ApplicationEditPage extends React.Component { getOrganizations() { OrganizationBackend.getOrganizations("admin") .then((res) => { - if (res?.status === "error") { + if (res.status === "error") { this.setState({ isAuthorized: false, }); } else { this.setState({ - organizations: (res.msg === undefined) ? res : [], + organizations: res.data || [], }); } });