mirror of
https://github.com/denoland/deno.git
synced 2024-11-24 15:19:26 -05:00
perf(lsp): fix redundant clones for ts responses (#21445)
This commit is contained in:
parent
32438d25c3
commit
28c527c8f5
1 changed files with 1 additions and 2 deletions
|
@ -4443,8 +4443,7 @@ fn request(
|
||||||
let state = op_state.borrow_mut::<State>();
|
let state = op_state.borrow_mut::<State>();
|
||||||
|
|
||||||
performance.measure(mark);
|
performance.measure(mark);
|
||||||
if let Some(response) = state.response.clone() {
|
if let Some(response) = state.response.take() {
|
||||||
state.response = None;
|
|
||||||
Ok(response.data)
|
Ok(response.data)
|
||||||
} else {
|
} else {
|
||||||
Err(custom_error(
|
Err(custom_error(
|
||||||
|
|
Loading…
Reference in a new issue