Skip to content

Commit

Permalink
[FIX]이미지 url S3버전으로 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
Hong0329 committed Apr 2, 2024
1 parent 39e4d66 commit e545bee
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
@Service
@RequiredArgsConstructor
public class AuthServiceImpl implements AuthService {
private final static String GHOST_IMAGE = "https://github.com/TeamDon-tBe/SERVER/assets/97835512/fb3ea04c-661e-4221-a837-854d66cdb77e";

@Value("${aws-property.s3-default-image-url}")
private String GHOST_IMAGE_S3;
Expand Down Expand Up @@ -57,7 +56,7 @@ public AuthResponseDto socialLogin(String socialAccessToken, AuthRequestDto auth
.nickname(DEFAULT_NICKNAME)//.nickname(socialData.getNickname())
.socialPlatform(socialPlatform)
.socialId(socialData.getId())
.profileUrl(GHOST_IMAGE)
.profileUrl(GHOST_IMAGE_S3)
.memberEmail(socialData.getEmail())
.socialNickname(socialData.getNickname())
.build();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ public class MemberCommandService {
private final CommentLikedRepository commentLikedRepository;
private final ContentLikedRepository contentLikedRepository;
private final S3Service s3Service;
private final String DEFAULT_PROFILE_URL = "https://github.com/TeamDon-tBe/SERVER/assets/97835512/fb3ea04c-661e-4221-a837-854d66cdb77e";
private final static String GHOST_IMAGE = "https://github.com/TeamDon-tBe/SERVER/assets/97835512/fb3ea04c-661e-4221-a837-854d66cdb77e";

@Value("${aws-property.s3-default-image-url}")
Expand All @@ -53,7 +52,7 @@ public void withdrawalMember(Long memberId, MemberWithdrawalPatchRequestDto memb
List<Ghost> ghosts = ghostRepository.findByGhostTargetMember(member);

member.updateNickname("탈퇴한 회원");
member.updateProfileUrl(DEFAULT_PROFILE_URL);
member.updateProfileUrl(GHOST_IMAGE_S3);
member.updateDeletedReason(memberWithdrawalPatchRequestDto.deleted_reason());

notificationRepository.deleteBynotificationTargetMember(member);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import com.dontbe.www.DontBeServer.api.notification.dto.response.NotificationAllResponseDtoVer2;
import com.dontbe.www.DontBeServer.api.notification.repository.NotificationRepository;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.data.domain.PageRequest;
import org.springframework.data.domain.Slice;
import org.springframework.stereotype.Service;
Expand All @@ -24,8 +25,9 @@ public class NotificationQueryService {
private final MemberRepository memberRepository;
private final NotificationRepository notificationRepository;
private final CommentRepository commentRepository;
private final String SYSTEM_PROFILEURL = "https://github.com/TeamDon-tBe/SERVER/assets/128011308/327d416e-ef1f-4c10-961d-4d9b85632d87";

@Value("${aws-property.s3-system-image-url}")
private String SYSTEM_IMAGE_S3;
private final int NOTIFICATION_DEFAULT_PAGE_SIZE = 15;

public NotificaitonCountResponseDto countUnreadNotification(Long memberId) {
Expand Down Expand Up @@ -95,7 +97,7 @@ private String profileUrl(Long notificationId, String triggerType){
Member triggerMember = memberRepository.findMemberByIdOrThrow(notification.getNotificationTriggerMemberId());
return triggerMember.getProfileUrl();
}else{
return SYSTEM_PROFILEURL;
return SYSTEM_IMAGE_S3;
}
}

Expand Down

0 comments on commit e545bee

Please sign in to comment.