mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI-examples.git
synced 2025-09-04 15:49:23 +00:00
fix of checkWebAppData method call
This commit is contained in:
@@ -68,7 +68,7 @@ suspend fun main(vararg args: String) {
|
|||||||
val requestBody = call.receiveText()
|
val requestBody = call.receiveText()
|
||||||
val webAppCheckData = Json { }.decodeFromString(WebAppDataWrapper.serializer(), requestBody)
|
val webAppCheckData = Json { }.decodeFromString(WebAppDataWrapper.serializer(), requestBody)
|
||||||
|
|
||||||
val isSafe = telegramBotAPIUrlsKeeper.checkWebAppLink(webAppCheckData.data, webAppCheckData.hash)
|
val isSafe = telegramBotAPIUrlsKeeper.checkWebAppData(webAppCheckData.data, webAppCheckData.hash)
|
||||||
|
|
||||||
call.respond(HttpStatusCode.OK, isSafe.toString())
|
call.respond(HttpStatusCode.OK, isSafe.toString())
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user