rails_jwt_auth 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +6 -2
- data/app/models/concerns/rails_jwt_auth/recoverable.rb +6 -0
- 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: b96c7a63119aa045fa08e184f4ab932fbcaf4b1b
|
4
|
+
data.tar.gz: 0d2823aee7a5f58f4586f03769bcba83e9dd96ef
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b6165a6384a25f04e987da4a7e41dad7336fdeb830934cff72875412846aa43900e5ee3b9c11e0e77987decef9c8505f3b8e72bdd37ad4700a2f4c746a6faad1
|
7
|
+
data.tar.gz: 6b49902ab3d1c3f88409c7ccda8bc3008268d59a5a812961eab9797a010686e6b713eefb80e2f61637b141a519f0e441b54fb4b1b69b5a6f0b1a2ef4ba95f913
|
data/README.md
CHANGED
@@ -281,7 +281,9 @@ Confirmation api is defined by RailsJwtAuth::ConfirmationsController.
|
|
281
281
|
url: host/confirmation,
|
282
282
|
method: POST,
|
283
283
|
data: {
|
284
|
-
|
284
|
+
confirmation: {
|
285
|
+
email: "user@example.com"
|
286
|
+
}
|
285
287
|
}
|
286
288
|
}
|
287
289
|
```
|
@@ -297,7 +299,9 @@ Password api is defined by RailsJwtAuth::PasswordsController.
|
|
297
299
|
url: host/password,
|
298
300
|
method: POST,
|
299
301
|
data: {
|
300
|
-
|
302
|
+
password: {
|
303
|
+
email: "user@example.com"
|
304
|
+
}
|
301
305
|
}
|
302
306
|
}
|
303
307
|
```
|
@@ -17,6 +17,12 @@ module RailsJwtAuth
|
|
17
17
|
base.send(:field, :reset_password_token, type: String)
|
18
18
|
base.send(:field, :reset_password_sent_at, type: Time)
|
19
19
|
end
|
20
|
+
|
21
|
+
base.send(:before_update) do
|
22
|
+
if password_digest_changed? && reset_password_token
|
23
|
+
self.reset_password_token = nil
|
24
|
+
end
|
25
|
+
end
|
20
26
|
end
|
21
27
|
end
|
22
28
|
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.3.
|
4
|
+
version: 0.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- rjurado
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-03-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|