Skip to content

Commit

Permalink
fix: 중복된 구조체 삭제
Browse files Browse the repository at this point in the history
  • Loading branch information
dami0806 committed Feb 11, 2024
1 parent b09022c commit 81779c8
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 8 deletions.
6 changes: 0 additions & 6 deletions On_off_iOS/On_off_iOS/Bookmark/KeyChain/KeyChain.swift
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,6 @@ enum LoginKeyChain: String {
case refreshToken
}

/// 토큰 유효성 확인 토큰 키체인 값
struct TokenValidationRequest: Codable {
let accessToken: String
let refreshToken: String
}

/// login 종류 식별
enum LoginMethod: String{
case loginMethod
Expand Down
2 changes: 1 addition & 1 deletion On_off_iOS/On_off_iOS/Launch/LaunchViewModel.swift
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ final class LaunchViewModel {
}

// 토큰 유효성 검사 요청
let request = TokenValidationRequest(accessToken: accessToken, refreshToken: refreshToken)
let request = TokenResult(accessToken: accessToken, refreshToken: refreshToken)
return self.loginService.validateTokenAndSendInfo(request: request)
.map { response in
response.isSuccess ? .main : .login // 응답 성공 시 메인, 실패 시 로그인으로
Expand Down
2 changes: 1 addition & 1 deletion On_off_iOS/On_off_iOS/LogIn/Service/LoginService.swift
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ final class LoginService: LoginProtocol {
/// 유효성 검사하기
/// - Parameter request: 서버에서 발급받는 Token
/// - Returns: Tokens
func validateTokenAndSendInfo(request: TokenValidationRequest) -> Observable<Response<TokenResult>> {
func validateTokenAndSendInfo(request: TokenResult) -> Observable<Response<TokenResult>> {
let url = Domain.RESTAPI + LoginPath.checkValidation.rawValue
let headers = Header.header.getHeader()

Expand Down

0 comments on commit 81779c8

Please sign in to comment.