cargo format

This commit is contained in:
Muhammad Mominul Huque 2019-06-15 13:37:15 +06:00
parent f032eeb05f
commit ebb40c7f87
No known key found for this signature in database
GPG key ID: 37AF141540DE557D
4 changed files with 4 additions and 12 deletions

View file

@ -399,8 +399,7 @@ fn on_notification(
Ok(mut params) => {
let uri = params.text_document.uri;
let path = uri.to_file_path().map_err(|()| format!("invalid uri: {}", uri))?;
let text =
params.content_changes.pop().ok_or_else(|| format!("empty changes"))?.text;
let text = params.content_changes.pop().ok_or_else(|| format!("empty changes"))?.text;
state.vfs.write().change_file_overlay(path.as_path(), text);
return Ok(());
}
@ -548,11 +547,7 @@ where
error: None,
}
} else {
RawResponse::err(
id,
ErrorCode::InternalError as i32,
e.to_string()
)
RawResponse::err(id, ErrorCode::InternalError as i32, e.to_string())
}
}
},