summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authoralpaylan2021-04-16 03:54:29 +0300
committeralpaylan2021-04-16 03:54:29 +0300
commitf759c6b4da459ae2544c6cb5b0e19e4367fef57f (patch)
tree6249c732906352336fa38c371b6ec9c2a5ea7dc9 /src
parente923a69e503c81a38736f9eb3ea65e4c8551dee5 (diff)
downloadgradecoin-f759c6b4da459ae2544c6cb5b0e19e4367fef57f.tar.gz
gradecoin-f759c6b4da459ae2544c6cb5b0e19e4367fef57f.tar.bz2
gradecoin-f759c6b4da459ae2544c6cb5b0e19e4367fef57f.zip
work on post auth transaction 201 test
Diffstat (limited to 'src')
-rw-r--r--src/handlers.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/handlers.rs b/src/handlers.rs
index 88f9a80..b7b1007 100644
--- a/src/handlers.rs
+++ b/src/handlers.rs
@@ -608,9 +608,11 @@ pub async fn authorized_propose_transaction(
608 // it has been changed since 608 // it has been changed since
609 609
610 let hashed_transaction = Md5::digest(&serde_json::to_vec(&new_transaction).unwrap()); 610 let hashed_transaction = Md5::digest(&serde_json::to_vec(&new_transaction).unwrap());
611 611 println!("{:?}", new_transaction);
612 println!("{:?}", &serde_json::to_vec(&new_transaction).unwrap());
613 println!("{:x}", hashed_transaction);
612 if token_payload.claims.tha != format!("{:x}", hashed_transaction) { 614 if token_payload.claims.tha != format!("{:x}", hashed_transaction) {
613 debug!( 615 println!(
614 "the hash of the request {:x} did not match the hash given in jwt {:?}", 616 "the hash of the request {:x} did not match the hash given in jwt {:?}",
615 hashed_transaction, token_payload.claims.tha 617 hashed_transaction, token_payload.claims.tha
616 ); 618 );