From aa6ac13a18a7ee039c2e2fa502c097919900782d Mon Sep 17 00:00:00 2001 From: Jamie Stackhouse Date: Mon, 20 Jul 2015 14:45:40 -0300 Subject: [PATCH] Changed default "New" to use NewWithClaims internally. --- jwt.go | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/jwt.go b/jwt.go index cfe2d6b..b76c873 100644 --- a/jwt.go +++ b/jwt.go @@ -32,14 +32,7 @@ type Token struct { // Create a new Token. Takes a signing method func New(method SigningMethod) *Token { - return &Token{ - Header: map[string]interface{}{ - "typ": "JWT", - "alg": method.Alg(), - }, - Claims: MapClaim{}, - Method: method, - } + return NewWithClaims(method, MapClaim{}) } func NewWithClaims(method SigningMethod, claims Claims) *Token {