rails_jwt_auth 0.23.0 → 0.23.1

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
  SHA256:
3
- metadata.gz: ece5fffcb405896636167d181c6d75ef80a69c02b244c2310490ad48fde1c19b
4
- data.tar.gz: df24cb6685d1de75e4639678801bc205011ee3d713a41ad765044bf994da449a
3
+ metadata.gz: 30dd056bd39f52415bc62c4d1ff401cb0c5eae1e8a3d106e462cb264ebcd2565
4
+ data.tar.gz: 95dd99f7ce26037ce8aa6e64782cb004c4fa3782468645a41d3fbeb317e4fecc
5
5
  SHA512:
6
- metadata.gz: dbda81eef8a5117e1e1e53458f78c4aa2db1b3277539b8b7a5786058d441f2025d0273c353c96d55f2f6a90d54336ba6da13bcad3fad932863ae15b7e70978e6
7
- data.tar.gz: 7423f74466fe56424ae6170469c64bf60326b303e578b74ece7a8c90ba06f79f4fa87d1b49b79d7b0f3a64633a208a9992d45c5cbecf430a14ea43a5efa132af
6
+ metadata.gz: 936f43e24f01fc3e05bb36dc6e17335b12e319fbbdcc75953630e5c2f542f8a94f8d1c49d667cdf7e138a845ad2235c72a81c09712e987a53643d4d8741d0aad
7
+ data.tar.gz: 4fc9640ee03f5390a1b64b915d7fe761164f5e9fa859b4c3d35c05a953329228f2f0a7c81c3d1221fc9150783d6089a26998a39829b9527b686a19bb67c5c2b3
@@ -2,8 +2,8 @@ if defined?(ActionMailer)
2
2
  class RailsJwtAuth::Mailer < ApplicationMailer
3
3
  default from: RailsJwtAuth.mailer_sender
4
4
 
5
- def confirmation_instructions(user)
6
- @user = user
5
+ def confirmation_instructions(id)
6
+ @user = RailsJwtAuth.model.find(id)
7
7
 
8
8
  if RailsJwtAuth.confirmation_url
9
9
  url, params = RailsJwtAuth.confirmation_url.split('?')
@@ -19,8 +19,8 @@ if defined?(ActionMailer)
19
19
  mail(to: @user.unconfirmed_email || @user.email, subject: subject)
20
20
  end
21
21
 
22
- def reset_password_instructions(user)
23
- @user = user
22
+ def reset_password_instructions(id)
23
+ @user = RailsJwtAuth.model.find(id)
24
24
 
25
25
  if RailsJwtAuth.reset_password_url
26
26
  url, params = RailsJwtAuth.reset_password_url.split('?')
@@ -36,8 +36,8 @@ if defined?(ActionMailer)
36
36
  mail(to: @user.email, subject: subject)
37
37
  end
38
38
 
39
- def set_password_instructions(user)
40
- @user = user
39
+ def set_password_instructions(id)
40
+ @user = RailsJwtAuth.model.find(id)
41
41
 
42
42
  if RailsJwtAuth.set_password_url
43
43
  url, params = RailsJwtAuth.set_password_url.split('?')
@@ -53,8 +53,8 @@ if defined?(ActionMailer)
53
53
  mail(to: @user.email, subject: subject)
54
54
  end
55
55
 
56
- def send_invitation(user)
57
- @user = user
56
+ def send_invitation(id)
57
+ @user = RailsJwtAuth.model.find(id)
58
58
 
59
59
  if RailsJwtAuth.accept_invitation_url
60
60
  url, params = RailsJwtAuth.accept_invitation_url.split '?'
@@ -10,7 +10,7 @@ module RailsJwtAuth
10
10
  self.confirmation_sent_at = Time.now
11
11
  return false unless save
12
12
 
13
- mailer = Mailer.confirmation_instructions(self)
13
+ mailer = Mailer.confirmation_instructions(id)
14
14
  RailsJwtAuth.deliver_later ? mailer.deliver_later : mailer.deliver
15
15
  true
16
16
  end
@@ -67,7 +67,7 @@ module RailsJwtAuth
67
67
  self.confirmation_token = SecureRandom.base58(24)
68
68
  self.confirmation_sent_at = Time.now
69
69
 
70
- mailer = Mailer.confirmation_instructions(self)
70
+ mailer = Mailer.confirmation_instructions(id)
71
71
  RailsJwtAuth.deliver_later ? mailer.deliver_later : mailer.deliver
72
72
  end
73
73
  end
@@ -114,7 +114,7 @@ module RailsJwtAuth
114
114
  end
115
115
 
116
116
  def send_invitation_mail
117
- mailer = Mailer.send_invitation(self)
117
+ mailer = Mailer.send_invitation(id)
118
118
  RailsJwtAuth.deliver_later ? mailer.deliver_later : mailer.deliver
119
119
  end
120
120
 
@@ -10,7 +10,7 @@ module RailsJwtAuth
10
10
  self.reset_password_sent_at = Time.now
11
11
  return false unless save
12
12
 
13
- mailer = Mailer.reset_password_instructions(self)
13
+ mailer = Mailer.reset_password_instructions(id)
14
14
  RailsJwtAuth.deliver_later ? mailer.deliver_later : mailer.deliver
15
15
  end
16
16
 
@@ -25,7 +25,7 @@ module RailsJwtAuth
25
25
  self.reset_password_sent_at = Time.now
26
26
  return false unless save
27
27
 
28
- mailer = Mailer.set_password_instructions(self)
28
+ mailer = Mailer.set_password_instructions(id)
29
29
  RailsJwtAuth.deliver_later ? mailer.deliver_later : mailer.deliver
30
30
  true
31
31
  end
@@ -1,3 +1,3 @@
1
1
  module RailsJwtAuth
2
- VERSION = '0.23.0'
2
+ VERSION = '0.23.1'
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.23.0
4
+ version: 0.23.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - rjurado
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-07-12 00:00:00.000000000 Z
11
+ date: 2019-02-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bcrypt