Skip to content

Commit

Permalink
Handle generated schedule IDs correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
kazimuth committed Sep 24, 2024
1 parent 57fbb5f commit b371e6d
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions crates/core/src/db/datastore/locking_tx_datastore/mut_tx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -156,13 +156,7 @@ impl MutTxId {
reducer_name: schedule.reducer_name,
};
let (generated, ..) = self.insert(ST_SCHEDULED_ID, &mut row.into(), database_address)?;
let id = generated.as_product().and_then(|p| {
if p.elements.len() == 1 {
p.elements[0].as_u32()
} else {
None
}
});
let id = generated.as_u32();

if let Some(&id) = id {
let (table, ..) = self.get_or_create_insert_table_mut(table_id)?;
Expand Down

0 comments on commit b371e6d

Please sign in to comment.