isomorfeus-i18n 22.9.0.rc4 → 22.9.0.rc6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/isomorfeus/i18n/init.rb +6 -1
- data/lib/isomorfeus/i18n/version.rb +1 -1
- data/lib/lucid_i18n_mixin.rb +4 -1
- metadata +8 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 43251b5ba4fa5178c1d2a4617b1e2b7e2d2b4b61e1606a05bc53f98e11f086d2
|
4
|
+
data.tar.gz: 39e3edb0cd4bee6b81879664cb1e5380343e34b6c25eb87dfe22ccd7a95b0cf4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9f4cc34e0016bf97ecc61172ea1238b63a6d06ffcf630497a94713d5398b025bfbfe1101d5a6889c25e68f9113da41f93e83810deae66a4021c717ee4a950f3d
|
7
|
+
data.tar.gz: 16f702ded5af32d754468e47e86448d38a23c17869d7ff116dad9b034c54d1c8597b9ca9927f6017c142ae658eda42621c4f7768eec8ac3091d1b974a3f5640b
|
data/lib/isomorfeus/i18n/init.rb
CHANGED
@@ -8,7 +8,12 @@ module Isomorfeus
|
|
8
8
|
end
|
9
9
|
else
|
10
10
|
def init
|
11
|
-
|
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
|
data/lib/lucid_i18n_mixin.rb
CHANGED
@@ -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.
|
4
|
+
version: 22.9.0.rc6
|
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-
|
11
|
+
date: 2022-09-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -114,28 +114,28 @@ dependencies:
|
|
114
114
|
requirements:
|
115
115
|
- - '='
|
116
116
|
- !ruby/object:Gem::Version
|
117
|
-
version: 22.9.0.
|
117
|
+
version: 22.9.0.rc6
|
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.
|
124
|
+
version: 22.9.0.rc6
|
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.
|
131
|
+
version: 22.9.0.rc6
|
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.
|
138
|
+
version: 22.9.0.rc6
|
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.
|
159
|
+
version: 22.9.0.rc6
|
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.
|
166
|
+
version: 22.9.0.rc6
|
167
167
|
- !ruby/object:Gem::Dependency
|
168
168
|
name: rake
|
169
169
|
requirement: !ruby/object:Gem::Requirement
|