From 6a6cf54f16165df216a345c2ba01d4bd02a3b7e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=9E=84=EB=8F=99=ED=98=84?= Date: Mon, 18 Dec 2023 22:17:58 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20=EC=9A=B0=EC=82=B0=20=EB=B0=98=EB=82=A9?= =?UTF-8?q?=20=EC=8B=9C=20=EC=9A=B0=EC=82=B0=20=EC=9C=84=EC=B9=98=20?= =?UTF-8?q?=EB=B3=80=EA=B2=BD=20(#411)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/upbrella/be/rent/service/RentService.java | 2 +- src/main/java/upbrella/be/umbrella/entity/Umbrella.java | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/upbrella/be/rent/service/RentService.java b/src/main/java/upbrella/be/rent/service/RentService.java index 05de823d..5a9b684a 100644 --- a/src/main/java/upbrella/be/rent/service/RentService.java +++ b/src/main/java/upbrella/be/rent/service/RentService.java @@ -116,7 +116,7 @@ public void returnUmbrellaByUser(User userToReturn, ReturnUmbrellaByUserRequest History updatedHistory = History.updateHistoryForReturn(history, returnStore, request); Umbrella returnedUmbrella = history.getUmbrella(); - returnedUmbrella.returnUmbrella(); + returnedUmbrella.returnUmbrella(returnStore); rentRepository.save(updatedHistory); addImprovementReportFromReturnByUser(updatedHistory, request); diff --git a/src/main/java/upbrella/be/umbrella/entity/Umbrella.java b/src/main/java/upbrella/be/umbrella/entity/Umbrella.java index adb93e6e..f7a72bf9 100644 --- a/src/main/java/upbrella/be/umbrella/entity/Umbrella.java +++ b/src/main/java/upbrella/be/umbrella/entity/Umbrella.java @@ -73,8 +73,9 @@ public void rentUmbrella() { this.rentable = false; } - public void returnUmbrella() { + public void returnUmbrella(StoreMeta storeMeta) { + this.storeMeta = storeMeta; this.rentable = true; }