Fix typo of AuthenticationChallengeResponsable

This commit is contained in:
onevcat
2021-08-20 21:32:17 +09:00
parent c7deab70ca
commit 733d22d456
2 changed files with 8 additions and 5 deletions

View File

@@ -26,8 +26,11 @@
import Foundation
@available(*, deprecated, message: "Typo. Use `AuthenticationChallengeResponsible` instead", renamed: "AuthenticationChallengeResponsible")
public typealias AuthenticationChallengeResponsable = AuthenticationChallengeResponsible
/// Protocol indicates that an authentication challenge could be handled.
public protocol AuthenticationChallengeResponsable: AnyObject {
public protocol AuthenticationChallengeResponsible: AnyObject {
/// Called when a session level authentication challenge is received.
/// This method provide a chance to handle and response to the authentication
@@ -61,7 +64,7 @@ public protocol AuthenticationChallengeResponsable: AnyObject {
completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void)
}
extension AuthenticationChallengeResponsable {
extension AuthenticationChallengeResponsible {
public func downloader(
_ downloader: ImageDownloader,

View File

@@ -143,7 +143,7 @@ open class ImageDownloader {
/// A responder for authentication challenge.
/// Downloader will forward the received authentication challenge for the downloading session to this responder.
open weak var authenticationChallengeResponder: AuthenticationChallengeResponsable?
open weak var authenticationChallengeResponder: AuthenticationChallengeResponsible?
private let name: String
private var session: URLSession
@@ -473,8 +473,8 @@ extension ImageDownloader {
}
}
// Use the default implementation from extension of `AuthenticationChallengeResponsable`.
extension ImageDownloader: AuthenticationChallengeResponsable {}
// Use the default implementation from extension of `AuthenticationChallengeResponsible`.
extension ImageDownloader: AuthenticationChallengeResponsible {}
// Use the default implementation from extension of `ImageDownloaderDelegate`.
extension ImageDownloader: ImageDownloaderDelegate {}