Skip to content

Commit 603b388

Browse files
committed
Add usize to RedisValue converter
1 parent f084ffb commit 603b388

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/redismodule.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,12 @@ impl From<Vec<i64>> for RedisValue {
5151
}
5252
}
5353

54+
impl From<usize> for RedisValue {
55+
fn from(i: usize) -> Self {
56+
(i as i64).into()
57+
}
58+
}
59+
5460
///////////////////////////////////////////////////
5561

5662
pub trait NextArg: Iterator {

0 commit comments

Comments
 (0)