auth_rails 1.1.1 → 1.1.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
  SHA256:
3
- metadata.gz: 15e71bc7d2e92cc25d3433db5adbd5608f70c5fbf9de27a234106d95d54d9957
4
- data.tar.gz: cfab483acafa215d5530e8ec90904cdceadb55bb53074b69ad73c2ef756ab7ca
3
+ metadata.gz: ec319ee060ab65bae9b8352f0273020bce76b16b747c7fd0563d4469f493fa7f
4
+ data.tar.gz: 8ff6a24a175f38e3e7faad76c129889d56607710a1371af678cdd41a6e592e34
5
5
  SHA512:
6
- metadata.gz: 92bbbfb5274f625b03f8879d9b5cf3f6e61d577a8c30e53bda9cd374e74b46fc821717c7bac9f116502d64f5f1fb55571cd424d0583de3a4b260726c0d4c5ffc
7
- data.tar.gz: c4479a4db819b2ba649fed888c074185c751ffbccb71ba4278c9747c01adb9cb3bcf8e0db5eb47c3db60d7b015cb37bb64c4d4c63cb77bab869a4a0ef45d9da2
6
+ metadata.gz: 68f21b701758b484019f1ecee6b5b7cf69e038793eb2adfc30c7c288f27818c83714c217988286afbcc010d26ad9a0e716d0221d13861544de536c90839a2f06
7
+ data.tar.gz: 7c807efb6163c2c8ab27ed168e10565495ef2f4bcc7cd288428795722b73fa7cec64fd44b84160ee61158d97b60efd07dd01e7bf95a58bdf71d4a766a38739c4
@@ -10,7 +10,11 @@ module AuthRails
10
10
  secret_key: Configuration::Jwt::AccessToken.secret_key
11
11
  )
12
12
 
13
- CurrentAuth.user = AuthRails.resource_class.find_by(AuthRails.identifier_name => payload[:sub])
13
+ CurrentAuth.user = AuthRails.retrieve_resource(
14
+ params: {
15
+ AuthRails.identifier_name => payload[:sub]
16
+ }
17
+ )
14
18
 
15
19
  raise AuthRails.error_class, :unauthenticated unless CurrentAuth.user
16
20
  end
@@ -68,6 +68,10 @@ export default defineConfig({
68
68
  text: 'API Reference',
69
69
  link: '/api-reference',
70
70
  },
71
+ {
72
+ text: 'Changelogs',
73
+ link: '/changelogs',
74
+ },
71
75
  ],
72
76
  outline: {
73
77
  level: [2, 3],
@@ -0,0 +1,22 @@
1
+ # Changelogs
2
+
3
+ ## v1.1.1
4
+
5
+ add optional chaning when `identifier_name` is not provided from config
6
+
7
+ **Full Changelog**: https://github.com/zgid123/auth_rails/compare/v1.1.0...v1.1.1
8
+
9
+ ## v1.1.0
10
+
11
+ - allow custom identifier column and validate password method
12
+ - allow custom `retrieve_resource` method
13
+
14
+ **Full Changelog**: https://github.com/zgid123/auth_rails/compare/v1.0.2...v1.1.0
15
+
16
+ ## v1.0.2
17
+
18
+ - require `jwt` inside gem
19
+ - remove `allowed_token` when doing refresh for api controller
20
+ - create generator for configuration and migration for `allowed_token` strategy
21
+
22
+ **Full Changelog**: https://github.com/zgid123/auth_rails/compare/v1.0.0...v1.0.2
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module AuthRails
4
- VERSION = '1.1.1'
4
+ VERSION = '1.1.2'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: auth_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alpha
@@ -42,6 +42,7 @@ files:
42
42
  - biome.json
43
43
  - docs/.vitepress/config.mts
44
44
  - docs/src/api-reference.md
45
+ - docs/src/changelogs.md
45
46
  - docs/src/cli/configuration.md
46
47
  - docs/src/cli/migration.md
47
48
  - docs/src/customization/complex-retrieve-resource.md