Skip to content

Commit

Permalink
refactor: 삭제 권한 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
sectionr0 committed Sep 9, 2023
1 parent ef65002 commit 0ba1c24
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ class AccountService(
}

fun deleteAccount(currentAccount: Account, accountId: Long): Boolean {
currentAccount.role.checkAdminAndManager()
currentAccount.role.checkAdmin()
val account = getAccountById(accountId)
refreshTokenRepository.deleteByAccountId(accountId)
accountRepository.delete(account)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package kr.co.bookand.backend.common

import org.springframework.web.bind.annotation.GetMapping
import org.springframework.web.bind.annotation.PostMapping
import org.springframework.web.bind.annotation.RestController

@RestController
Expand All @@ -9,4 +10,9 @@ class HealthController {
fun hello(): String {
return "BOOKAND REST API Server is running!"
}

@PostMapping("/")
fun health(): String {
return "BOOKAND REST API Server is running!"
}
}

0 comments on commit 0ba1c24

Please sign in to comment.