zeta: Scope edit prediction event history to current project (#37595)
This change also causes Zeta to not do anything for editors that are not associated with a project. In practice, this shouldn't affect any behavior - those editors shouldn't have edit predictions anyway. Release Notes: - Edit Prediction: Requests no longer include recent edits from other projects (other Zed windows).
This commit is contained in:
@@ -207,9 +207,10 @@ fn assign_edit_prediction_provider(
|
||||
|
||||
if let Some(buffer) = &singleton_buffer
|
||||
&& buffer.read(cx).file().is_some()
|
||||
&& let Some(project) = editor.project()
|
||||
{
|
||||
zeta.update(cx, |zeta, cx| {
|
||||
zeta.register_buffer(buffer, cx);
|
||||
zeta.register_buffer(buffer, project, cx);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user