simple_token_authentication 1.18.0 → 1.18.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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a6aca3b41664f8049ffe17c95b1c89c8664cfb5d5f98e352a4bf45e634a3d583
|
4
|
+
data.tar.gz: fb1df872ad44fe0cd0f8f7153893d484173f33103d16aa3c607167be042eeaa3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 43aa19854353c443d99d7050ec6899b054b0267c51d5163fdce9a932ee897f490ab91b159baa33f848f2178721666168e34a044223aec8964795dcd3d132319f
|
7
|
+
data.tar.gz: 0d5f1c666e52098abdaed64233d3d32aa8e8759c8ef0d853e53504648a7e4799215865f63cf53cd5df81e1f6a8da73d56aeddd0511c77cebac0f58c9d1371a36
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,12 @@
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
4
4
|
This project adheres to [Semantic Versioning](http://semver.org/).
|
5
5
|
|
6
|
+
## [1.18.1] - 2023-01-03
|
7
|
+
|
8
|
+
### Fixed
|
9
|
+
|
10
|
+
- Fix a regression introduced by #402, that caused hooks not to be invoked - @dmke
|
11
|
+
|
6
12
|
## [1.18.0] - 2022-12-27
|
7
13
|
|
8
14
|
### Added
|
@@ -294,7 +300,8 @@ This project adheres to [Semantic Versioning](http://semver.org/).
|
|
294
300
|
This [gist][gist] did refactor the Jose Valim's code into an `ActiveSupport::Concern`.
|
295
301
|
|
296
302
|
[gist]: https://gist.github.com/gonzalo-bulnes/7659739
|
297
|
-
[Unreleased]: https://github.com/gonzalo-bulnes/simple_token_authentication/compare/v1.18.
|
303
|
+
[Unreleased]: https://github.com/gonzalo-bulnes/simple_token_authentication/compare/v1.18.1...master
|
304
|
+
[1.18.1]: https://github.com/gonzalo-bulnes/simple_token_authentication/compare/v1.18.0...v1.18.1
|
298
305
|
[1.18.0]: https://github.com/gonzalo-bulnes/simple_token_authentication/compare/v1.17.0...v1.18.0
|
299
306
|
[1.17.0]: https://github.com/gonzalo-bulnes/simple_token_authentication/compare/v1.16.0...v1.17.0
|
300
307
|
[1.16.0]: https://github.com/gonzalo-bulnes/simple_token_authentication/compare/v1.15.1...v1.16.0
|
@@ -32,7 +32,7 @@ module SimpleTokenAuthentication
|
|
32
32
|
|
33
33
|
if token_correct?(record, entity, token_comparator)
|
34
34
|
perform_sign_in!(record, sign_in_handler)
|
35
|
-
after_successful_token_authentication if respond_to?(:after_successful_token_authentication)
|
35
|
+
after_successful_token_authentication if respond_to?(:after_successful_token_authentication, true)
|
36
36
|
end
|
37
37
|
end
|
38
38
|
|
@@ -736,6 +736,21 @@ describe 'Any class which includes SimpleTokenAuthentication::TokenAuthenticatio
|
|
736
736
|
expect(token_authentication_handler).to have_received(:after_successful_token_authentication).once
|
737
737
|
end
|
738
738
|
end
|
739
|
+
|
740
|
+
context 'when the handler implements a private :after_successful_token_authentication', protected: true do
|
741
|
+
before(:each) do
|
742
|
+
token_authentication_handler.singleton_class.send(:include, Module.new {
|
743
|
+
def after_successful_token_authentication; end
|
744
|
+
private :after_successful_token_authentication
|
745
|
+
})
|
746
|
+
allow(token_authentication_handler).to receive(:after_successful_token_authentication)
|
747
|
+
end
|
748
|
+
|
749
|
+
it 'calls the :after_successful_token_authentication hook' do
|
750
|
+
token_authentication_handler.send(:authenticate_entity_from_token!, double)
|
751
|
+
expect(token_authentication_handler).to have_received(:after_successful_token_authentication).once
|
752
|
+
end
|
753
|
+
end
|
739
754
|
end
|
740
755
|
end
|
741
756
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: simple_token_authentication
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.18.
|
4
|
+
version: 1.18.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gonzalo Bulnes Guilpain
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-01-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: actionmailer
|