We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 37d6a3d commit 0b69834Copy full SHA for 0b69834
src/descriptor/mod.rs
@@ -617,6 +617,10 @@ impl Descriptor<DescriptorPublicKey> {
617
618
/// Get all possible assets for a given descriptor
619
pub fn all_assets(&self) -> Result<Vec<Assets>, Error> {
620
+ let threshold = self.count_assets();
621
+ if threshold >= 1000 {
622
+ return Err(Error::MaxAssetThresholdExceeded);
623
+ }
624
match self {
625
Descriptor::Bare(k) => Ok(k.as_inner().all_assets()),
626
Descriptor::Pkh(k) => {
0 commit comments