Show full URL in settings when WebDAV is used

This commit is contained in:
Torsten Grote 2024-06-18 10:53:18 -03:00
parent f5c2f0bd3a
commit f52b1004fb
No known key found for this signature in database
GPG key ID: 3E5F77D92CF891FF

View file

@ -6,7 +6,6 @@
package com.stevesoltys.seedvault.backend.webdav package com.stevesoltys.seedvault.backend.webdav
import android.content.Context import android.content.Context
import android.net.Uri
import android.util.Log import android.util.Log
import androidx.annotation.WorkerThread import androidx.annotation.WorkerThread
import com.stevesoltys.seedvault.R import com.stevesoltys.seedvault.R
@ -42,7 +41,7 @@ internal class WebDavHandler(
companion object { companion object {
fun createWebDavProperties(context: Context, config: WebDavConfig): WebDavProperties { fun createWebDavProperties(context: Context, config: WebDavConfig): WebDavProperties {
val host = Uri.parse(config.url).host val host = config.url.removePrefix("https://")
return WebDavProperties( return WebDavProperties(
config = config, config = config,
name = context.getString(R.string.storage_webdav_name, host), name = context.getString(R.string.storage_webdav_name, host),