make clippy happy

This commit is contained in:
Marc Planard 2023-06-04 12:56:24 +02:00
parent ec15004085
commit c5654c7ae0

View File

@ -51,9 +51,9 @@ pub struct RedisCtrl {
impl RedisCtrl { impl RedisCtrl {
pub fn new() -> Result<Self, Box<dyn std::error::Error>> { pub fn new() -> Result<Self, Box<dyn std::error::Error>> {
let client = Client::open("redis://127.0.0.1/") let client = Client::open("redis://127.0.0.1/")
.map_err(| err | LJError::RedisConnect(err))?; .map_err(LJError::RedisConnect)?;
let connection = client.get_connection() let connection = client.get_connection()
.map_err(| err | LJError::RedisConnect(err))?; .map_err(LJError::RedisConnect)?;
Ok(RedisCtrl { client, connection }) Ok(RedisCtrl { client, connection })
} }