lex-microsoft_teams 0.6.25 → 0.6.26

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: 42353a2d92e77ba3659f2ab93c24339efca2e869a4ae18d30621b5fb3e3cd947
4
- data.tar.gz: 4420f02e9d66c85c673e6411203b06fa49862d9a5a16ef78cf7b55a366da3a8d
3
+ metadata.gz: fb7445b3bb8025805c3d81e13d2b45a2739d364ae566e722699b200648d2b29b
4
+ data.tar.gz: 6915059592314205c3d4bbac82188dfe980fa8fc294c14dbc6de30e583c65065
5
5
  SHA512:
6
- metadata.gz: b165c26eca6e63b1d181a0aee9a2bfadd72039e2cda558bc33fc08e49a1ba1730af044012dcb6936848c03b02ca7d30c00be6678c5e4e9665070f2811b24ec4a
7
- data.tar.gz: bdae821120daca1fcd888c57cc2a2996aced5b8270e88332235dc4c2ee71fe1a0f4533f6b5a28df6761f78f3bb233e7aafb4f92db4c33fec518cf1d39d78584e
6
+ metadata.gz: 33ce7326e6fd50fe558b43dacaa5808448074901e96d144af1f3ccc28a847d23e9c8c18e82152b3b1874bcf622fa8d6171c5c1bce951663d67e229eb758ec039
7
+ data.tar.gz: 5cdf2b3081b0c40d59cbc199808ff5bcbd4ae9d0f64cff5365e07c3428621c341c33813db0cbcf396c71034e6356dcf3295efbb0b8fbbc47de2f654f0d581fb2
data/CHANGELOG.md CHANGED
@@ -2,6 +2,11 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [0.6.26] - 2026-03-29
6
+
7
+ ### Fixed
8
+ - `Helpers::TokenCache` — replaced direct `Legion::Crypt.get(path)` call with `vault_get` from `Legion::Crypt::Helper` (included via `include Legion::Crypt::Helper`); `vault_path` accepts an optional `_suffix` argument so the helper's delegation pattern is compatible
9
+
5
10
  ## [0.6.25] - 2026-03-28
6
11
 
7
12
  ### Fixed
@@ -104,7 +104,8 @@ module Legion
104
104
 
105
105
  def teams_auth_settings
106
106
  settings = if defined?(Legion::Settings)
107
- Legion::Settings.dig(:microsoft_teams, :auth) || {}
107
+ ms = Legion::Settings[:microsoft_teams]
108
+ (ms && ms[:auth]) || {}
108
109
  else
109
110
  {}
110
111
  end
@@ -99,7 +99,8 @@ module Legion
99
99
 
100
100
  def teams_auth_settings
101
101
  settings = if defined?(Legion::Settings)
102
- Legion::Settings.dig(:microsoft_teams, :auth) || {}
102
+ ms = Legion::Settings[:microsoft_teams]
103
+ (ms && ms[:auth]) || {}
103
104
  else
104
105
  {}
105
106
  end
@@ -12,6 +12,7 @@ module Legion
12
12
  class TokenCache
13
13
  include Legion::Extensions::Helpers::Lex if Legion::Extensions.const_defined?(:Helpers, false) &&
14
14
  Legion::Extensions::Helpers.const_defined?(:Lex, false)
15
+ include Legion::Crypt::Helper if defined?(Legion::Crypt::Helper)
15
16
 
16
17
  REFRESH_BUFFER = 60
17
18
  DEFAULT_LOCAL_DIR = File.join(Dir.home, '.legionio', 'tokens')
@@ -133,7 +134,7 @@ module Legion
133
134
  def load_from_vault
134
135
  if vault_available?
135
136
  log.info("Loading delegated token from Vault (#{vault_path})")
136
- data = Legion::Crypt.get(vault_path)
137
+ data = vault_get
137
138
  if data && data[:access_token]
138
139
  @mutex.synchronize do
139
140
  @delegated_cache = {
@@ -270,7 +271,7 @@ module Legion
270
271
  delegated[:refresh_buffer] || REFRESH_BUFFER
271
272
  end
272
273
 
273
- def vault_path
274
+ def vault_path(_suffix = nil)
274
275
  settings = teams_auth_settings
275
276
  delegated = settings[:delegated]
276
277
  custom = delegated[:vault_path] if delegated.is_a?(Hash)
@@ -385,7 +386,8 @@ module Legion
385
386
  def teams_auth_settings
386
387
  return {} unless defined?(Legion::Settings)
387
388
 
388
- Legion::Settings.dig(:microsoft_teams, :auth) || {}
389
+ ms = Legion::Settings[:microsoft_teams]
390
+ (ms && ms[:auth]) || {}
389
391
  end
390
392
  end
391
393
  end
@@ -3,7 +3,7 @@
3
3
  module Legion
4
4
  module Extensions
5
5
  module MicrosoftTeams
6
- VERSION = '0.6.25'
6
+ VERSION = '0.6.26'
7
7
  end
8
8
  end
9
9
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lex-microsoft_teams
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.25
4
+ version: 0.6.26
5
5
  platform: ruby
6
6
  authors:
7
7
  - Esity