checking the authentication if works

This commit is contained in:
Gouri Panda 2023-10-08 01:53:14 +05:30
parent 852deaf57b
commit 0b4b223692

View File

@ -71,11 +71,11 @@ fun ProductFlavor.fetchUrl(): String {
return url return url
.openConnection() .openConnection()
.apply { .apply {
if (urlString.isAuthenticationUrl){ if (urlString.isAuthenticationUrl) {
setRequestProperty( // setRequestProperty(
"Authorization", // "Authorization",
"Basic ${Base64.getEncoder().encodeToString(System.getenv(secretKey).toByteArray())}" // "Basic ${Base64.getEncoder().encodeToString(System.getenv(secretKey).toByteArray())}"
) // )
} }
connect() connect()
getInputStream() getInputStream()