isomorfeus-i18n 22.9.0.rc5 → 22.9.0.rc7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 87b02ffdd0f9ee7b4d19db6d2d661b1263ed2d73aa5e07363290ad064a333d38
4
- data.tar.gz: 2df1caf537c2d0a70b7205e78219e7118458e1906e48a066a177f31b49133be9
3
+ metadata.gz: bf6628875a0aef580fedddb02f0cef5019159c3972ddf11484a009862771b9fd
4
+ data.tar.gz: 961ce8a6caefb802f9236175949b232c5b3d9dbf5259a9b209e4ffae2bb45afc
5
5
  SHA512:
6
- metadata.gz: 6295d563090c4d3975ce9890c7f981e0618e92dce87d586678176e0b1800ef3fc9175bb2f55942ab51adb46a75d6daec9e40485a5258c6df72744c1da77592a8
7
- data.tar.gz: f43646f7a764ef9198f2f1f4ff08aa60f394e21b394fac929406125b27d4980b1db97c2fc294c729f91e8fcfcde3b908b971701a60fc4be32ccb86c2b60b32cb
6
+ metadata.gz: a36c63842a919f4aaa4588d5b022133c749e9dfd2f6f512a66106b7193af2020b1ff80b5d6d274d0daeb2243bd244f39c02b9edd290217c0c2c52e5da1bee622
7
+ data.tar.gz: 2774fe167ddf3944bf9530e0a79790c518eb8aad791dea5948bd7fa820b4977f355ae562d2a99b5dc29ac6c03c7bf8540d1733edab1ad4c2bf988ca4d3068746
@@ -8,7 +8,12 @@ module Isomorfeus
8
8
  end
9
9
  else
10
10
  def init
11
- return if Thread.current[:isomorfeus_i18n_initialized] == true
11
+ dev = Isomorfeus.development?
12
+ if (!dev && Thread.current[:isomorfeus_i18n_initialized] == true) ||
13
+ (dev && (Time.now - (Thread.current[:isomorfeus_i18n_last_update] || 0)) < 0.020)
14
+ return
15
+ end
16
+ Thread.current[:isomorfeus_i18n_last_update] = Time.now if dev
12
17
  unless Dir.exist?(Isomorfeus.locale_path)
13
18
  STDERR.puts "locale directory '#{Isomorfeus.locale_path}' not found, please create it if using I18n"
14
19
  return
@@ -1,5 +1,5 @@
1
1
  module Isomorfeus
2
2
  module I18n
3
- VERSION = '22.9.0.rc5'
3
+ VERSION = '22.9.0.rc7'
4
4
  end
5
5
  end
@@ -157,8 +157,11 @@ module LucidI18nMixin
157
157
  end
158
158
  else # RUBY_ENGINE
159
159
  def _send_i18n_method(method, args)
160
- Isomorfeus.store.deferred_dispatch(type: 'I18N_LOAD', domain: i18n_domain, locale: current_locale, method: method, args: args)
161
160
  result = Isomorfeus.store.dig(:i18n_state, i18n_domain, current_locale, method, JSON.dump(args))
161
+ if result.nil? || Isomorfeus.development?
162
+ Isomorfeus.store.deferred_dispatch(type: 'I18N_LOAD', domain: i18n_domain, locale: current_locale, method: method, args: args)
163
+ result = Isomorfeus.store.dig(:i18n_state, i18n_domain, current_locale, method, JSON.dump(args))
164
+ end
162
165
  result || ''
163
166
  end
164
167
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: isomorfeus-i18n
3
3
  version: !ruby/object:Gem::Version
4
- version: 22.9.0.rc5
4
+ version: 22.9.0.rc7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jan Biedermann
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-09-25 00:00:00.000000000 Z
11
+ date: 2022-09-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -100,42 +100,42 @@ dependencies:
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: 0.15.4
103
+ version: 0.15.5
104
104
  type: :runtime
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: 0.15.4
110
+ version: 0.15.5
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: isomorfeus-redux
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
115
  - - '='
116
116
  - !ruby/object:Gem::Version
117
- version: 22.9.0.rc5
117
+ version: 22.9.0.rc7
118
118
  type: :runtime
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
122
  - - '='
123
123
  - !ruby/object:Gem::Version
124
- version: 22.9.0.rc5
124
+ version: 22.9.0.rc7
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: isomorfeus-transport
127
127
  requirement: !ruby/object:Gem::Requirement
128
128
  requirements:
129
129
  - - '='
130
130
  - !ruby/object:Gem::Version
131
- version: 22.9.0.rc5
131
+ version: 22.9.0.rc7
132
132
  type: :runtime
133
133
  prerelease: false
134
134
  version_requirements: !ruby/object:Gem::Requirement
135
135
  requirements:
136
136
  - - '='
137
137
  - !ruby/object:Gem::Version
138
- version: 22.9.0.rc5
138
+ version: 22.9.0.rc7
139
139
  - !ruby/object:Gem::Dependency
140
140
  name: r18n-core
141
141
  requirement: !ruby/object:Gem::Requirement
@@ -156,14 +156,14 @@ dependencies:
156
156
  requirements:
157
157
  - - '='
158
158
  - !ruby/object:Gem::Version
159
- version: 22.9.0.rc5
159
+ version: 22.9.0.rc7
160
160
  type: :development
161
161
  prerelease: false
162
162
  version_requirements: !ruby/object:Gem::Requirement
163
163
  requirements:
164
164
  - - '='
165
165
  - !ruby/object:Gem::Version
166
- version: 22.9.0.rc5
166
+ version: 22.9.0.rc7
167
167
  - !ruby/object:Gem::Dependency
168
168
  name: rake
169
169
  requirement: !ruby/object:Gem::Requirement