matrix-sdk: Don't use try_from for the u32 -> UInt conversion.

This commit is contained in:
Damir Jelić 2020-12-01 10:34:10 +01:00
parent ce4d53a88c
commit 50bd408d48

View file

@ -792,7 +792,7 @@ impl Client {
since: Option<&str>,
server: Option<&ServerName>,
) -> Result<get_public_rooms::Response> {
let limit = limit.map(|n| UInt::try_from(n).ok()).flatten();
let limit = limit.map(|n| UInt::from(n));
let request = assign!(get_public_rooms::Request::new(), {
limit,