Skip to content

Commit

Permalink
fix: issue bug
Browse files Browse the repository at this point in the history
  • Loading branch information
sectionr0 committed Jul 29, 2023
1 parent cf571f5 commit 75fdd59
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,12 @@ class IssueService(
var fileDto = FileDto("", "")
if (createIssueRequest.logFile != null) {
val multipartFile = createIssueRequest.logFile
fileDto = awsS3Service.uploadV2(multipartFile, "reportLog", "loginAccount")
fileDto = awsS3Service.uploadV2(multipartFile, "reportLog", owner = currentAccount.email)
}
val issue = Issue(createIssueRequest, 1L)

if (createIssueRequest.sendLogs) {
issue.setLogFile(fileDto.url, fileDto.fileName)
issue.setLogFile(fileDto.fileUrl, fileDto.fileName)
}

val saveIssue: Issue = issueRepository.save(issue)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class AwsS3Service(


fun uploadFiles(uploadFileRequest: UploadFileRequest): FileListDto {
val currentAccountEmail = "SecurityUtil.getCurrentAccountEmail()"
val currentAccountEmail = getCurrentAccountEmail()
val files = uploadFileRequest.files
if (CollectionUtils.isEmpty(files)) {
throw BookandException(ErrorCode.INPUT_VALID_ERROR)
Expand Down
4 changes: 2 additions & 2 deletions src/test/kotlin/kr/co/bookand/backend/IssueServiceTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ class IssueServiceTest : BehaviorSpec({
)

val fileDto = FileDto(
url = "url",
fileName = "fileName"
fileName = "fileName",
fileUrl = "url"
)


Expand Down

0 comments on commit 75fdd59

Please sign in to comment.