Fix readme

This commit is contained in:
Vincent Prouillet 2017-11-14 17:18:25 +01:00
parent eae3743017
commit 7907b1cd79
2 changed files with 1 additions and 2 deletions

View File

@ -81,7 +81,7 @@ Last but not least, you will need to set the algorithm(s) allowed for this token
```rust
use jsonwebtoken::{Validation, Algorithm};
// Default valuation: the only algo allowed is HS256
// Default validation: the only algo allowed is HS256
let validation = Validation::default();
// Quick way to setup a validation where only the algorithm changes
let validation = Validation::new(Algorithm::HS512);

View File

@ -102,5 +102,4 @@ fn decode_header_only() {
let header = decode_header(token).unwrap();
assert_eq!(header.alg, Algorithm::HS256);
assert_eq!(header.typ, Some("JWT".to_string()));
}