mirror of
https://github.com/usbharu/Hideout.git
synced 2026-07-22 13:13:54 +00:00
refactor: HttpSignatureSignerImplをリファクタリング
This commit is contained in:
@@ -55,13 +55,13 @@ class HttpSignatureSignerImpl : HttpSignatureSigner {
|
||||
signHeaders: List<String>
|
||||
): String {
|
||||
headers.toMap().map { it.key.lowercase() to it.value }.toMap()
|
||||
val result = signHeaders.map {
|
||||
val result = signHeaders.joinToString("\n") {
|
||||
if (it.startsWith("(")) {
|
||||
specialHeader(it, url, method)
|
||||
} else {
|
||||
generalHeader(it, headers.get(it)!!)
|
||||
}
|
||||
}.joinToString("\n")
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user