mirror of
https://github.com/alexgo-io/bitcoin-indexer.git
synced 2026-01-12 16:52:57 +08:00
fix: stacks predicate format
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
use crate::utils::{AbstractStacksBlock, Context};
|
||||
|
||||
use super::types::{
|
||||
BlockIdentifierIndexRule, HookAction, StacksChainhookSpecification,
|
||||
BlockIdentifierIndexRule, ExactMatchingRule, HookAction, StacksChainhookSpecification,
|
||||
StacksContractDeploymentPredicate, StacksPredicate,
|
||||
};
|
||||
use chainhook_types::{
|
||||
@@ -399,7 +399,9 @@ pub fn evaluate_stacks_predicate_on_transaction<'a>(
|
||||
}
|
||||
false
|
||||
}
|
||||
StacksPredicate::Txid(txid) => txid.eq(&transaction.transaction_identifier.hash),
|
||||
StacksPredicate::Txid(ExactMatchingRule::Equals(txid)) => {
|
||||
txid.eq(&transaction.transaction_identifier.hash)
|
||||
}
|
||||
StacksPredicate::BlockHeight(_) => unreachable!(),
|
||||
}
|
||||
}
|
||||
|
||||
@@ -738,7 +738,7 @@ pub enum StacksPredicate {
|
||||
FtEvent(StacksFtEventBasedPredicate),
|
||||
NftEvent(StacksNftEventBasedPredicate),
|
||||
StxEvent(StacksStxEventBasedPredicate),
|
||||
Txid(String),
|
||||
Txid(ExactMatchingRule),
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, JsonSchema)]
|
||||
|
||||
Reference in New Issue
Block a user