Remove Document from VulcanServerError
This commit is contained in:
parent
29a1dc73f7
commit
de2a887188
3 changed files with 1 additions and 5 deletions
|
@ -442,7 +442,6 @@ public class io/github/wulkanowy/sdk/scrapper/exception/VulcanException : io/git
|
|||
}
|
||||
|
||||
public final class io/github/wulkanowy/sdk/scrapper/exception/VulcanServerError : io/github/wulkanowy/sdk/scrapper/exception/VulcanException {
|
||||
public final fun getDoc ()Lorg/jsoup/nodes/Document;
|
||||
public final fun getHttpCode ()I
|
||||
}
|
||||
|
||||
|
|
|
@ -1,9 +1,6 @@
|
|||
package io.github.wulkanowy.sdk.scrapper.exception
|
||||
|
||||
import org.jsoup.nodes.Document
|
||||
|
||||
class VulcanServerError internal constructor(
|
||||
message: String,
|
||||
val doc: Document,
|
||||
val httpCode: Int,
|
||||
) : VulcanException(message)
|
||||
|
|
|
@ -92,7 +92,7 @@ internal class ErrorInterceptor(
|
|||
}
|
||||
|
||||
when (doc.title()) {
|
||||
"Błąd" -> throw VulcanServerError(doc.body().text(), doc, httpCode)
|
||||
"Błąd" -> throw VulcanServerError(doc.body().text(), httpCode)
|
||||
"Błąd strony" -> throw VulcanException(doc.select(".errorMessage").text(), httpCode)
|
||||
"Logowanie" -> throw AccountPermissionException(
|
||||
buildString {
|
||||
|
|
Loading…
Reference in a new issue