mumsnet_jwt 2.1.4 → 2.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/mumsnet_jwt.rb +2 -2
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9fb58ee43b66fcde04db7f334c2cda8fc9269b13
4
- data.tar.gz: f23760a174cf0e16eb1367c7ed39b6984a646de3
3
+ metadata.gz: aadd88b0e4d6ee25b320644656a96a4cd1c25f3a
4
+ data.tar.gz: 5900c62cedc469bac4729db305f0aa9a5c9e3ca4
5
5
  SHA512:
6
- metadata.gz: 4713e226e069c95736128fad40b9d798a753d26b34195d7cf88c2ea80494b9c7a0c7661d206701e7db91015e78044fec46aab83356c07ed032c9e0494b927249
7
- data.tar.gz: 71d04f2b36c75c818243aa58cea2984bd2b10bb13f496f9d251a8fe57646aa445ad77cbbe49d75d5a36c0529f2f24112f0fc89ab0ead5a926cbd8c737c2dcc1b
6
+ metadata.gz: 4455ba7bac462958ae2a9f734c313e58ab0410aa9f0934ab003ee72a9f94d5b32381697a0e4203d1bf5778494775e14e0308301e2817d123a6cc1f6ba14cd261
7
+ data.tar.gz: 538f877f8d8a1f29a22569eb39397f99a6c6801127019558e059bdfcf56d51b37e2b2fa2a74426df11cfa7ac2aabf0ab2363aed1886af974d86d272e42137f47
data/lib/mumsnet_jwt.rb CHANGED
@@ -6,7 +6,7 @@ module MumsnetJWT
6
6
  DEFAULT_EXP = Time.now.utc.to_i + 60 * 60 * 24
7
7
  def tokenify(extra_payload: {})
8
8
  return false if env_defined?
9
- payload = { client_id: ENV['JWT_CLIENT_ID'], iss: ENV['JWT_ISSUER'], exp: DEFAULT_EXP }.merge(extra_payload)
9
+ payload = { client_id: ENV['JWT_CLIENT_ID'], exp: DEFAULT_EXP }.merge(extra_payload)
10
10
  JWT.encode payload, jwt_secret, 'HS256' unless jwt_secret.nil?
11
11
  end
12
12
 
@@ -60,7 +60,7 @@ module MumsnetJWT
60
60
  private
61
61
 
62
62
  def env_defined?
63
- ENV['JWT_CLIENT_ID'].nil? || ENV['JWT_SECRETS'].nil? || ENV['JWT_ISSUER'].nil?
63
+ ENV['JWT_CLIENT_ID'].nil? || ENV['JWT_SECRETS'].nil?
64
64
  end
65
65
 
66
66
  def client_id_from_token(token)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mumsnet_jwt
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.4
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Murray Catto