Don't serialize typ if None

This commit is contained in:
Vincent Prouillet 2017-08-26 09:54:20 +09:00
parent 43a20030ee
commit 5839cb4552
1 changed files with 1 additions and 0 deletions

View File

@ -8,6 +8,7 @@ pub struct Header {
/// The type of JWS: it can only be "JWT" here
///
/// Defined in [RFC7515#4.1.9](https://tools.ietf.org/html/rfc7515#section-4.1.9).
#[serde(skip_serializing_if = "Option::is_none")]
typ: Option<String>,
/// The algorithm used
///