Skip to content

Commit

Permalink
#7 isValidLoginData : 데이터 처리
Browse files Browse the repository at this point in the history
  • Loading branch information
seondal committed Dec 24, 2021
1 parent e7f2489 commit 3dcba4c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
Binary file not shown.
7 changes: 6 additions & 1 deletion DalTube/DalTube/Login/UserSignService.swift
Original file line number Diff line number Diff line change
Expand Up @@ -50,5 +50,10 @@ struct UserSignService {
}
}


private func isValidLoginData(data: Data) -> NetworkResult<Any> {
let decoder = JSONDecoder()
guard let decodedData = try? decoder.decode(LoginResponseData.self, from: data)
else {return .pathErr}
return .success(decodedData)
}
}

0 comments on commit 3dcba4c

Please sign in to comment.