con.query_row("SELECT [id], [title], [description] FROM [Recipe] WHERE [id] = ?1", [id], |row| {
Ok(model::Recipe::new(row.get("id")?, row.get("title")?, row.get("description")?))
}).map_err(DBError::from)
}
pub fn get_user_login_info(&self, token: &str) -> Result<UserLoginInfo> {
con.query_row("SELECT [id], [title], [description] FROM [Recipe] WHERE [id] = ?1", [id], |row| {
Ok(model::Recipe::new(row.get("id")?, row.get("title")?, row.get("description")?))
}).map_err(DBError::from)
}
pub fn get_user_login_info(&self, token: &str) -> Result<UserLoginInfo> {