mirror of https://github.com/lapce/lapce.git
Merge pull request #1357 from MinusGix/fix-proxy-hang
Fix proxy hang due to held lock
This commit is contained in:
commit
233a32d558
|
@ -385,7 +385,8 @@ pub fn handle_response(
|
|||
id: RequestId,
|
||||
result: Result<ProxyResponse, RpcError>,
|
||||
) {
|
||||
if let Some(handler) = self.pending.lock().remove(&id) {
|
||||
let handler = { self.pending.lock().remove(&id) };
|
||||
if let Some(handler) = handler {
|
||||
handler.invoke(result);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue