i18n_screwdriver 12.1.0 → 12.1.1

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: 8937b8c32adcdbba9b064772d37c7a8d3de9dbb30c85ede88a2cd51b05510640
4
- data.tar.gz: e028cdbf6b7d5a2c29c44c194be466836b1a149f42cdb8d71d4cfbc1a4d33517
3
+ metadata.gz: 05aaf7ca5ff02f062cb0647e74017de3fdaca3b7fc38b73cbdaf4c2c4d53ed10
4
+ data.tar.gz: a4c4bf18d3c4f5d6317d8b94ad84b402788ceaebbf64352ab76c055cd79e0729
5
5
  SHA512:
6
- metadata.gz: 2f154c5bab402124e89d3eb7267df2c2a2f0362a0a5664f876b6d813e3e49a166b3da07fb51ce7f4a5cf54251eb44932046ebb94479801a31f1aba29cf6565b4
7
- data.tar.gz: 269f8c922afe8a9dbda6e1b06419417f0ecb110da7c9b5e832f519eb8471564e9ffb1a1406a7c6dd4f58ff5cc51a439dc57785c8b15d0dd807e88d6450f89cec
6
+ metadata.gz: ae833ac1921bfc08952d204f71a842a5deec12eaabdef2d3709e3c1cb9011920a910a0dc0f548d9401b65825cb84f916979901151e256630807a2ebbdd9be7e3
7
+ data.tar.gz: 267af9014f6ece7300ad7d6ced01de29f106f3dfaffac0d7e2c8f5bd687ce953fb1970b564c74310c5a659cdc894bd522ab54eccc7e8e2ecd5fc272ceb3866ba
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- i18n_screwdriver (12.1.0)
4
+ i18n_screwdriver (12.1.1)
5
5
  rails (>= 3.0.0)
6
6
 
7
7
  GEM
@@ -1,3 +1,3 @@
1
1
  module I18nScrewdriver
2
- VERSION = "12.1.0"
2
+ VERSION = "12.1.1"
3
3
  end
@@ -176,7 +176,12 @@ module I18nScrewdriver
176
176
  end
177
177
 
178
178
  def self.translate(string, **options)
179
- escaped_options = options.transform_values { |v| v.gsub("|", "<PIPE/>") }
179
+ escaped_options = options.transform_values do |value|
180
+ next value unless value.is_a?(String)
181
+
182
+ value.gsub("|", "<PIPE/>")
183
+ end
184
+
180
185
  I18n.translate!(generate_key(string), **escaped_options).split("|").last.gsub("<PIPE/>", "|")
181
186
  rescue I18n::MissingTranslationData
182
187
  I18n.translate(string, **options)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: i18n_screwdriver
3
3
  version: !ruby/object:Gem::Version
4
- version: 12.1.0
4
+ version: 12.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tobias Miesel
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2025-01-08 00:00:00.000000000 Z
12
+ date: 2025-01-09 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rspec