mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI.git
synced 2024-11-22 08:13:47 +00:00
fix not implemented error thrown
This commit is contained in:
parent
94f8c971c5
commit
3f896c2240
@ -40,6 +40,10 @@
|
||||
|
||||
### 0.26.4
|
||||
|
||||
* `TelegramBotAPI`:
|
||||
* Now any getting of updates will return `UnknownUpdateType` when inside of deserialization will be
|
||||
`SerializationException` or `NotImplemented` error
|
||||
|
||||
### 0.26.3
|
||||
|
||||
* `TelegramBotAPI`:
|
||||
|
@ -64,12 +64,16 @@ internal data class RawUpdate constructor(
|
||||
raw
|
||||
)
|
||||
}
|
||||
} catch (e: SerializationException) {
|
||||
UnknownUpdateType(
|
||||
updateId,
|
||||
raw.toString(),
|
||||
raw
|
||||
)
|
||||
} catch (e: Error) {
|
||||
when (e) {
|
||||
is SerializationException,
|
||||
is NotImplementedError -> UnknownUpdateType(
|
||||
updateId,
|
||||
raw.toString(),
|
||||
raw
|
||||
)
|
||||
else -> throw e
|
||||
}
|
||||
}.also {
|
||||
initedUpdate = it
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user