Skip to content

Commit 039bd8f

Browse files
committed
fix: CI error with collab_builder.rs
1 parent 25f5f61 commit 039bd8f

6 files changed

Lines changed: 9 additions & 12 deletions

File tree

frontend/rust-lib/collab-integrate/src/collab_builder.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ impl AppFlowyCollabBuilder {
284284
object.uid,
285285
object.workspace_id.clone(),
286286
object.object_id.to_string(),
287-
object.collab_type.clone(),
287+
object.collab_type,
288288
collab_db,
289289
persistence_config,
290290
);

frontend/rust-lib/flowy-core/src/deps_resolve/folder_deps/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ impl FolderQueryService for FolderServiceImpl {
197197
}
198198

199199
async fn get_collab(&self, object_id: &str, collab_type: CollabType) -> Option<QueryCollab> {
200-
let encode_collab = get_encoded_collab_v1_from_disk(&self.user, object_id, collab_type.clone())
200+
let encode_collab = get_encoded_collab_v1_from_disk(&self.user, object_id, collab_type)
201201
.await
202202
.ok();
203203

frontend/rust-lib/flowy-database2/src/manager.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -776,7 +776,7 @@ impl DatabaseCollabService for WorkspaceDatabaseCollabServiceImpl {
776776
collab_type: CollabType,
777777
encoded_collab: Option<(EncodedCollab, bool)>,
778778
) -> Result<Collab, DatabaseError> {
779-
let object = self.build_collab_object(object_id, collab_type.clone())?;
779+
let object = self.build_collab_object(object_id, collab_type)?;
780780
let data_source = if self.persistence.is_collab_exist(object_id) {
781781
trace!(
782782
"build collab: {}:{} from local encode collab",
@@ -796,7 +796,7 @@ impl DatabaseCollabService for WorkspaceDatabaseCollabServiceImpl {
796796
object_id,
797797
encoded_collab.is_none(),
798798
);
799-
match self.get_encode_collab(object_id, collab_type.clone()).await {
799+
match self.get_encode_collab(object_id, collab_type).await {
800800
Ok(Some(encode_collab)) => {
801801
info!(
802802
"build collab: {}:{} with remote encode collab, {} bytes",
@@ -885,7 +885,7 @@ impl DatabaseCollabService for WorkspaceDatabaseCollabServiceImpl {
885885
.filter_map(|object_id| {
886886
self
887887
.persistence
888-
.get_encoded_collab(object_id.as_str(), collab_type.clone())
888+
.get_encoded_collab(object_id.as_str(), collab_type)
889889
.map(|encoded_collab| (object_id.clone(), encoded_collab))
890890
})
891891
.collect();

frontend/rust-lib/flowy-server/src/af_cloud/impls/database.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ where
4545
let cloned_user = self.user.clone();
4646
let params = QueryCollabParams {
4747
workspace_id: workspace_id.clone(),
48-
inner: QueryCollab::new(object_id.clone(), collab_type.clone()),
48+
inner: QueryCollab::new(object_id.clone(), collab_type),
4949
};
5050
let result = try_get_client?.get_collab(params).await;
5151
match result {

frontend/rust-lib/flowy-server/src/supabase/api/collab_storage.rs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -64,11 +64,8 @@ where
6464

6565
async fn get_doc_state(&self, object: &CollabObject) -> Result<DataSource, Error> {
6666
let postgrest = self.server.try_get_weak_postgrest()?;
67-
let action = FetchObjectUpdateAction::new(
68-
object.object_id.clone(),
69-
object.collab_type.clone(),
70-
postgrest,
71-
);
67+
let action =
68+
FetchObjectUpdateAction::new(object.object_id.clone(), object.collab_type, postgrest);
7269
let doc_state = action.run().await?;
7370
Ok(DataSource::DocStateV1(doc_state))
7471
}

frontend/rust-lib/flowy-user/src/services/data_import/appflowy_data_import.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1248,7 +1248,7 @@ pub async fn upload_collab_objects_data(
12481248
objects.push(UserCollabParams {
12491249
object_id: oid,
12501250
encoded_collab,
1251-
collab_type: collab_type.clone(),
1251+
collab_type,
12521252
});
12531253
size_counter += obj_size;
12541254
}

0 commit comments

Comments
 (0)