Skip to content

Commit

Permalink
Remove duplicated validation
Browse files Browse the repository at this point in the history
  • Loading branch information
Thoralf-M committed Jan 12, 2024
1 parent a9cdb68 commit b8d1b63
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions sdk/src/types/block/output/feature/metadata.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,6 @@ fn verify_keys_packable<const VERIFY: bool>(
>,
) -> Result<(), Error> {
if VERIFY {
if map.is_empty() {
return Err(Error::InvalidMetadataFeatureKeyLength(
MetadataFeatureKeyLength::try_from(0u8).unwrap_err().into(),
));
}
for key in map.keys() {
if !key.iter().all(|b| b.is_ascii_graphic()) {
return Err(Error::NonGraphicAsciiMetadataKey(key.to_vec()));
Expand Down

0 comments on commit b8d1b63

Please sign in to comment.