Skip to content

Commit 5a1bb5e

Browse files
committedMar 4, 2025·
store: Do not return a StoreEvent from Layout.truncate_tables
1 parent 9886aa1 commit 5a1bb5e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed
 

‎store/postgres/src/relational.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ use graph::data::store::{Id, IdList, IdType, BYTES_SCALAR};
7373
use graph::data::subgraph::schema::POI_TABLE;
7474
use graph::prelude::{
7575
anyhow, info, BlockNumber, DeploymentHash, Entity, EntityOperation, Logger,
76-
QueryExecutionError, StoreError, StoreEvent, ValueType,
76+
QueryExecutionError, StoreError, ValueType,
7777
};
7878

7979
use crate::block_range::{BoundSide, BLOCK_COLUMN, BLOCK_RANGE_COLUMN};
@@ -1004,11 +1004,11 @@ impl Layout {
10041004
Ok(count)
10051005
}
10061006

1007-
pub fn truncate_tables(&self, conn: &mut PgConnection) -> Result<StoreEvent, StoreError> {
1007+
pub fn truncate_tables(&self, conn: &mut PgConnection) -> Result<(), StoreError> {
10081008
for table in self.tables.values() {
10091009
sql_query(&format!("TRUNCATE TABLE {}", table.qualified_name)).execute(conn)?;
10101010
}
1011-
Ok(StoreEvent::new(vec![]))
1011+
Ok(())
10121012
}
10131013

10141014
/// Revert the block with number `block` and all blocks with higher

0 commit comments

Comments
 (0)
Please sign in to comment.