瀏覽代碼

Make clear error codes are from HTTP

len 8 年之前
父節點
當前提交
dc882b4dce
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      app/src/main/java/eu/kanade/tachiyomi/data/network/OkHttpExtensions.kt

+ 1 - 1
app/src/main/java/eu/kanade/tachiyomi/data/network/OkHttpExtensions.kt

@@ -50,7 +50,7 @@ fun Call.asObservableSuccess(): Observable<Response> {
     return asObservable().doOnNext { response ->
         if (!response.isSuccessful) {
             response.close()
-            throw Exception("Unsuccessful code ${response.code()}")
+            throw Exception("HTTP error ${response.code()}")
         }
     }
 }