Skip to content

Commit

Permalink
fix: view editor used during initialization
Browse files Browse the repository at this point in the history
  • Loading branch information
richardshiue committed Nov 26, 2024
1 parent 45f7d6e commit f337acd
Showing 1 changed file with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1981,11 +1981,12 @@ impl DatabaseViewOperation for DatabaseViewOperationImpl {
}

async fn get_cells_for_field(&self, view_id: &str, field_id: &str) -> Vec<RowCell> {
let editor = self.editor_by_view_id.read().await.get(view_id).cloned();
match editor {
None => vec![],
Some(editor) => editor.v_get_cells_for_field(field_id).await,
}
self
.database
.read()
.await
.get_cells_for_field(view_id, field_id)
.await
}

async fn get_cell_in_row(&self, field_id: &str, row_id: &RowId) -> Arc<RowCell> {
Expand Down

0 comments on commit f337acd

Please sign in to comment.