Don't panic on missing mtime (#9513)

This is expected as of zed 0.128 when a new unsaved file is created

Release Notes:

- Fixed a panic when collaborating with newer zed versions
This commit is contained in:
Conrad Irwin 2024-03-18 14:19:33 -06:00 committed by GitHub
parent afda188334
commit f738bfd703
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -7747,10 +7747,13 @@ impl Project {
} }
let buffer_id = BufferId::new(state.id)?; let buffer_id = BufferId::new(state.id)?;
let buffer = cx.new_model(|_| { let buffer = Buffer::from_proto(
Buffer::from_proto(this.replica_id(), this.capability(), state, buffer_file) this.replica_id(),
.unwrap() this.capability(),
}); state,
buffer_file,
)?;
let buffer = cx.new_model(|_| buffer);
this.incomplete_remote_buffers this.incomplete_remote_buffers
.insert(buffer_id, Some(buffer)); .insert(buffer_id, Some(buffer));
} }