rails_jwt_auth 0.1.2 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 455eb1be0326b8c96bfe79eddbb78a166c3af9d5
4
- data.tar.gz: c7951ec26c6f9ba209bf1947d2a9240326328097
3
+ metadata.gz: a5288fa0196f845970d373d2052b248c3ce4b6b1
4
+ data.tar.gz: 1c2b2389f9f5505e9752f405e6a474e13ff561e9
5
5
  SHA512:
6
- metadata.gz: 37ab9c67d483c3cd4f57b116ac9431a7163d39d5c8458c48c5605d7d951df94516e366877d48c411ab980d8730e72b32592055a43ee3e958e6d371756aead1e5
7
- data.tar.gz: a554f15ee576cb07789f168e1010ac5c99f86859ac1613e1d8dd6d870b5632828dde728c2648a4d7162f0a39a45db36b81007ee3b6f822820d90002fc4d1cc56
6
+ metadata.gz: 8ca458720a5fa7f3f61ded128e6e88e2970ce07ad4c1e74c9a2512f638516eee6084db1901e9329400f5004803dca6e5c098227d562885ca4213d440b30ab52a
7
+ data.tar.gz: 408539140efb35dc7282567d9736eea1bdd5d5134542d0616b84b0c86c143f9f4710d2bb2c3849437a776dd2eea47dccc7fcaa7a42819db2f3a044757644705e
data/README.md CHANGED
@@ -225,7 +225,7 @@ Session api is defined by RailsJwtAuth::SessionsController.
225
225
  {
226
226
  url: host/session,
227
227
  method: DELETE,
228
- headers: { 'Authorization': 'auth_token'}
228
+ headers: { 'Authorization': 'Bearer auth_token'}
229
229
  }
230
230
  ```
231
231
 
@@ -254,7 +254,7 @@ Registration api is defined by RailsJwtAuth::RegistrationsController.
254
254
  {
255
255
  url: host/registration,
256
256
  method: DELETE,
257
- headers: { 'Authorization': 'auth_token'}
257
+ headers: { 'Authorization': 'Bearer auth_token'}
258
258
  }
259
259
  ```
260
260
 
@@ -2,7 +2,8 @@ module RailsJwtAuth
2
2
  module Jwt
3
3
  class Request
4
4
  def initialize(request)
5
- return unless (@jwt = request.env['HTTP_AUTHORIZATION'])
5
+ return unless request.env['HTTP_AUTHORIZATION']
6
+ @jwt = request.env['HTTP_AUTHORIZATION'].split.last
6
7
  @jwt_info = RailsJwtAuth::Jwt::Manager.decode(@jwt)
7
8
  end
8
9
 
@@ -1,3 +1,3 @@
1
1
  module RailsJwtAuth
2
- VERSION = '0.1.2'
2
+ VERSION = '0.2.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails_jwt_auth
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - rjurado
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-02-21 00:00:00.000000000 Z
11
+ date: 2017-02-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails