Skip to content

Commit

Permalink
hotfix: list 반환 타입 json으로 반환하도록 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
ori0o0p committed Sep 6, 2024
1 parent 59e7b49 commit 17ee9ff
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import com.repo.whopper.application.history.usecase.DeleteHistoryUseCase;
import com.repo.whopper.application.history.usecase.ViewHistoryUseCase;
import com.repo.whopper.common.annotation.OnlyTeacher;
import com.repo.whopper.common.http.response.DataResponseInfo;
import com.repo.whopper.interfaces.history.dto.HistoryResponse;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*;
Expand All @@ -20,8 +21,10 @@ class HistoryController {

@OnlyTeacher
@GetMapping
List<HistoryResponse> viewAll() {
return viewHistoryUseCase.viewAll();
DataResponseInfo<HistoryResponse> viewAll() {
final var result = viewHistoryUseCase.viewAll();

return DataResponseInfo.of(result);
}

@OnlyTeacher
Expand Down

0 comments on commit 17ee9ff

Please sign in to comment.