Enable clippy::needless_question_mark
(#8759)
This PR enables the [`clippy::needless_question_mark`](https://rust-lang.github.io/rust-clippy/master/index.html#/needless_question_mark) rule and fixes the outstanding violations. Release Notes: - N/A
This commit is contained in:
parent
33790b81fc
commit
a6dbaac653
10 changed files with 23 additions and 26 deletions
|
@ -952,14 +952,14 @@ impl Item for Editor {
|
|||
let buffer = project_item
|
||||
.downcast::<Buffer>()
|
||||
.map_err(|_| anyhow!("Project item at stored path was not a buffer"))?;
|
||||
Ok(pane.update(&mut cx, |_, cx| {
|
||||
pane.update(&mut cx, |_, cx| {
|
||||
cx.new_view(|cx| {
|
||||
let mut editor = Editor::for_buffer(buffer, Some(project), cx);
|
||||
|
||||
editor.read_scroll_position_from_db(item_id, workspace_id, cx);
|
||||
editor
|
||||
})
|
||||
})?)
|
||||
})
|
||||
})
|
||||
})
|
||||
.unwrap_or_else(|error| Task::ready(Err(error)))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue