From 7f9ac48b33129ba5a8e2497c6394a5647a0523f5 Mon Sep 17 00:00:00 2001 From: YugyeomGhim Date: Tue, 12 Nov 2024 15:24:20 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20argumentResolver=EC=97=90=EC=84=9C=20id?= =?UTF-8?q?=EB=A5=BC=20=EB=B0=98=ED=99=98=ED=95=98=EB=8F=84=EB=A1=9D=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/notai/auth/AuthArgumentResolver.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/notai/auth/AuthArgumentResolver.java b/src/main/java/notai/auth/AuthArgumentResolver.java index c81cb96..d832eba 100644 --- a/src/main/java/notai/auth/AuthArgumentResolver.java +++ b/src/main/java/notai/auth/AuthArgumentResolver.java @@ -25,7 +25,7 @@ public boolean supportsParameter(MethodParameter parameter) { } @Override - public Member resolveArgument( + public Long resolveArgument( MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, @@ -33,6 +33,6 @@ public Member resolveArgument( ) { HttpServletRequest request = (HttpServletRequest) webRequest.getNativeRequest(); Long memberId = (Long) request.getAttribute("memberId"); - return memberRepository.getById(memberId); + return memberRepository.getById(memberId).getId(); } }