Skip to content

Commit

Permalink
Remove dependency of vc_util on ic_cdk (#2153)
Browse files Browse the repository at this point in the history
* Remove dependency of vc_util on ic_cdk

* update Cargo.lock-files

* 🤖 cargo-fmt auto-update

---------

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
przydatek and github-actions[bot] authored Dec 20, 2023
1 parent b9fce85 commit 09d0533
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 8 deletions.
1 change: 0 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion demos/vc_issuer/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion src/vc_util/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ edition = "2021"
[dependencies]
# ic dependencies
candid.workspace = true
ic-cdk.workspace = true
ic-certification.workspace = true
ic-crypto-standalone-sig-verifier = { git = "https://github.com/dfinity/ic", rev = "bf9bc00b032a18d2dbcfcfcfb7a76a562f350c9e" }
ic-types = { git = "https://github.com/dfinity/ic", rev = "bf9bc00b032a18d2dbcfcfcfb7a76a562f350c9e" }
Expand Down
8 changes: 3 additions & 5 deletions src/vc_util/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -327,16 +327,14 @@ fn validate_claim<T: PartialEq<S> + std::fmt::Display, S: std::fmt::Display>(
if expected == actual {
Ok(())
} else {
ic_cdk::println!(
println!(
"inconsistent claim [{}] in VC:: expected: {}, actual: {}",
label,
expected,
actual
label, expected, actual
);
Err(inconsistent_jwt_claims("inconsistent claim in VC"))
}
} else {
ic_cdk::println!("missing claim [{}] in VC", label);
println!("missing claim [{}] in VC", label);
Err(inconsistent_jwt_claims("missing claim in VC"))
}
}
Expand Down

0 comments on commit 09d0533

Please sign in to comment.