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 +4 -4
- data/README.md +2 -2
- data/lib/rails_jwt_auth/jwt/request.rb +2 -1
- data/lib/rails_jwt_auth/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a5288fa0196f845970d373d2052b248c3ce4b6b1
|
4
|
+
data.tar.gz: 1c2b2389f9f5505e9752f405e6a474e13ff561e9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
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
|
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
|
|
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.
|
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-
|
11
|
+
date: 2017-02-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|