2021-04-19 14:34:08 +02:00
|
|
|
//
|
|
|
|
// APIService+Report.swift
|
|
|
|
// Mastodon
|
|
|
|
//
|
|
|
|
// Created by ihugo on 2021/4/19.
|
|
|
|
//
|
|
|
|
|
|
|
|
import Foundation
|
|
|
|
import MastodonSDK
|
|
|
|
import Combine
|
|
|
|
|
|
|
|
extension APIService {
|
|
|
|
|
|
|
|
func report(
|
|
|
|
domain: String,
|
|
|
|
query: Mastodon.API.Reports.FileReportQuery,
|
2021-07-20 10:40:04 +02:00
|
|
|
mastodonAuthenticationBox: MastodonAuthenticationBox
|
2021-04-19 14:34:08 +02:00
|
|
|
) -> AnyPublisher<Mastodon.Response.Content<Bool>, Error> {
|
|
|
|
let authorization = mastodonAuthenticationBox.userAuthorization
|
|
|
|
|
|
|
|
return Mastodon.API.Reports.fileReport(session: session, domain: domain, query: query, authorization: authorization)
|
|
|
|
}
|
|
|
|
}
|