diff --git a/app/build.gradle b/app/build.gradle index 8837f99e62..547f4aea8f 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -9,8 +9,8 @@ android { applicationId "org.ole.planet.myplanet" minSdkVersion 21 targetSdkVersion 34 - versionCode 1504 - versionName "0.15.4" + versionCode 1505 + versionName "0.15.5" ndkVersion '21.3.6528147' testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" vectorDrawables.useSupportLibrary = true diff --git a/app/src/main/java/org/ole/planet/myplanet/datamanager/ApiInterface.kt b/app/src/main/java/org/ole/planet/myplanet/datamanager/ApiInterface.kt index a662f8b4b8..ffde9d68a3 100644 --- a/app/src/main/java/org/ole/planet/myplanet/datamanager/ApiInterface.kt +++ b/app/src/main/java/org/ole/planet/myplanet/datamanager/ApiInterface.kt @@ -61,5 +61,5 @@ interface ApiInterface { fun checkAiProviders(@Url url: String?): Call @GET - fun getConfiguration(@Header("Authorization") header: String?, @Url url: String?): Call + fun getConfiguration(@Url url: String?): Call } diff --git a/app/src/main/java/org/ole/planet/myplanet/datamanager/Service.kt b/app/src/main/java/org/ole/planet/myplanet/datamanager/Service.kt index e7bde5e05b..dc479f48bc 100644 --- a/app/src/main/java/org/ole/planet/myplanet/datamanager/Service.kt +++ b/app/src/main/java/org/ole/planet/myplanet/datamanager/Service.kt @@ -312,8 +312,7 @@ class Service(private val context: Context) { couchdbURL = uri.scheme + "://" + url_user + ":" + url_pwd + "@" + uri.host + ":" + if (uri.port == -1) (if (uri.scheme == "http") 80 else 443) else uri.port } - val header= "Basic " + Base64.encodeToString(("$url_user:$url_pwd").toByteArray(), Base64.NO_WRAP) - retrofitInterface?.getConfiguration(header, getUrl(couchdbURL) + "/configurations/_all_docs?include_docs=true")?.enqueue(object : Callback { + retrofitInterface?.getConfiguration("${getUrl(couchdbURL)}/configurations/_all_docs?include_docs=true")?.enqueue(object : Callback { override fun onResponse(call: Call, response: Response) { if (response.isSuccessful) { val jsonObject = response.body()