Compare commits
2 Commits
269937ff09
...
4b9899c04e
Author | SHA1 | Date | |
---|---|---|---|
4b9899c04e | |||
e9e2b6415f |
@ -365,22 +365,12 @@ class SelfossApi(
|
|||||||
suspend fun update(): StatusAndData<String> =
|
suspend fun update(): StatusAndData<String> =
|
||||||
bodyOrFailure(
|
bodyOrFailure(
|
||||||
client.tryToGet(url("/update")) {
|
client.tryToGet(url("/update")) {
|
||||||
if (!shouldHavePostLogin()) {
|
|
||||||
parameter("username", appSettingsService.getUserName())
|
|
||||||
parameter("password", appSettingsService.getPassword())
|
|
||||||
}
|
|
||||||
if (appSettingsService
|
|
||||||
.getBasicUserName()
|
|
||||||
.isNotEmpty() &&
|
|
||||||
appSettingsService.getBasicPassword().isNotEmpty()
|
|
||||||
) {
|
|
||||||
headers {
|
headers {
|
||||||
append(
|
append(
|
||||||
HttpHeaders.Accept,
|
HttpHeaders.Accept,
|
||||||
"text/event-stream",
|
"text/event-stream",
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user