rails_jwt_auth 0.3.1 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d60421a50c1dab0343fadc2ada1393a41bf795fb
4
- data.tar.gz: 3a1d76f6c709d2d870ddf8e0b32d67e255457206
3
+ metadata.gz: b96c7a63119aa045fa08e184f4ab932fbcaf4b1b
4
+ data.tar.gz: 0d2823aee7a5f58f4586f03769bcba83e9dd96ef
5
5
  SHA512:
6
- metadata.gz: 6d260b269363d5e04a4857425bdfb45603e3da8d1c706b99dc39494c5a1156f68fb00796eaeabf09db0c4054cbca1d419011788b16683431ab40014b67d0c539
7
- data.tar.gz: 97b24203b7ae6c1153da28bcfcef026d0078511271783fea3e2cfdc27839ff2740a8e03835c9b2a9ba06328481a9df9983ca082986d8cac7999b7bb22183edd9
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
- email: "user@example.com"
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
- email: "user@example.com"
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
@@ -1,3 +1,3 @@
1
1
  module RailsJwtAuth
2
- VERSION = '0.3.1'
2
+ VERSION = '0.3.2'
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.3.1
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-02-28 00:00:00.000000000 Z
11
+ date: 2017-03-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails