fix(api): 콘텐츠 설정 PATCH 제외 API 파라미터를 제거한다

This commit is contained in:
Yu Sung
2026-03-27 22:28:21 +09:00
parent f542191d46
commit d369bc11f7
17 changed files with 234 additions and 379 deletions

View File

@@ -12,7 +12,7 @@ enum ExplorerApi {
case getCreatorRank
case getExplorer
case searchChannel(channel: String)
case getCreatorProfile(userId: Int, isAdultContentVisible: Bool)
case getCreatorProfile(userId: Int)
case getCreatorDetail(userId: Int)
case getFollowerList(userId: Int, page: Int, size: Int)
case getCreatorProfileCheers(userId: Int, page: Int, size: Int)
@@ -40,7 +40,7 @@ extension ExplorerApi: TargetType {
case .searchChannel:
return "/explorer/search/channel"
case .getCreatorProfile(let userId, _):
case .getCreatorProfile(let userId):
return "/explorer/profile/\(userId)"
case .getCreatorDetail(let userId):
@@ -90,8 +90,8 @@ extension ExplorerApi: TargetType {
case .searchChannel(let channel):
return .requestParameters(parameters: ["channel" : channel], encoding: URLEncoding.queryString)
case .getCreatorProfile(_, let isAdultContentVisible):
let parameters = ["isAdultContentVisible": isAdultContentVisible, "timezone": TimeZone.current.identifier] as [String: Any]
case .getCreatorProfile:
let parameters = ["timezone": TimeZone.current.identifier] as [String: Any]
return .requestParameters(parameters: parameters, encoding: URLEncoding.queryString)
case .getFollowerList(_, let page, let size):

View File

@@ -22,12 +22,7 @@ final class ExplorerRepository {
}
func getCreatorProfile(id: Int) -> AnyPublisher<Response, MoyaError> {
return api.requestPublisher(
.getCreatorProfile(
userId: id,
isAdultContentVisible: UserDefaults.isAdultContentVisible()
)
)
return api.requestPublisher(.getCreatorProfile(userId: id))
}
func getCreatorDetail(id: Int) -> AnyPublisher<Response, MoyaError> {