From a2ff72234d55534bb584adda302c8860de957529 Mon Sep 17 00:00:00 2001 From: CaptainB Date: Sun, 23 Apr 2023 18:00:55 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E5=A2=9E=E5=8A=A0runas=E4=BF=9D?= =?UTF-8?q?=E6=8A=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/io/metersphere/commons/utils/HttpHeaderUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/sdk-parent/sdk/src/main/java/io/metersphere/commons/utils/HttpHeaderUtils.java b/framework/sdk-parent/sdk/src/main/java/io/metersphere/commons/utils/HttpHeaderUtils.java index c837e67520..76a4f6aec6 100644 --- a/framework/sdk-parent/sdk/src/main/java/io/metersphere/commons/utils/HttpHeaderUtils.java +++ b/framework/sdk-parent/sdk/src/main/java/io/metersphere/commons/utils/HttpHeaderUtils.java @@ -53,7 +53,7 @@ public class HttpHeaderUtils { User user = sessionUserThreadLocal.get(); - if (user != null) { + if (user != null && SessionUtils.getUser() == null) { UserDTO userDTO = new UserDTO(); BeanUtils.copyProperties(user, userDTO); SessionUser sessionUser = SessionUser.fromUser(userDTO, UUID.randomUUID().toString());