Skip to content

Commit

Permalink
refactor: 불필요한 sender 파라미터 삭제
Browse files Browse the repository at this point in the history
  • Loading branch information
coli-geonwoo committed Oct 7, 2024
1 parent 1435ea6 commit 58691ce
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@

public record DirectMessage(Message message) {

public static DirectMessage createMessageToOther(Mate sender, Mate receiver, Notification recipientNotification) {
public static DirectMessage createMessageToOther(Mate receiver, Notification recipientNotification) {
Mate sender = recipientNotification.getMate();
Message message = Message.builder()
.putData("type", recipientNotification.getType().name())
.putData("nickname", sender.getNickname().getValue())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public void sendNudgeMessage(Mate requestMate, Mate nudgedMate) {
Notification nudgeNotification = notificationRepository.save(Notification.createNudge(requestMate));
fcmPushSender.sendNudgeMessage(
nudgeNotification,
DirectMessage.createMessageToOther(requestMate, nudgedMate, nudgeNotification)
DirectMessage.createMessageToOther(nudgedMate, nudgeNotification)
);
}

Expand Down

0 comments on commit 58691ce

Please sign in to comment.