localise_rails 0.1.3 → 0.1.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/localise_rails/update.rb +4 -4
- data/lib/localise_rails/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5ebf55a8896bc12f139cef5deb60c4ebd092c4d5c339dc34011905b1f852cf7f
|
4
|
+
data.tar.gz: f65f012e3a2c54f4c321fd50792c0e346160d7596fc9bb0bfb08794247c3e8f6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5664fb9e435ae1a52a79d71228751514bafbaf421109882c6c892ff475a21ef6016db1b7da98a19a5422d1495bea17211a997a7890a218734df0e2907334f2ed
|
7
|
+
data.tar.gz: 86507ff64de2f9999be362690bb684dbbbb3ae822d6ca69385d955d4c9d753eb2f4391cbf24b494fe4655e9a4d3f0a9b0012f8b0cc4dc8d284ffadd871832627
|
@@ -6,15 +6,15 @@ module LocaliseRails
|
|
6
6
|
query = LocaliseRails.config.options.map { |k, v| "#{k}=#{v}" }.join('&')
|
7
7
|
uri = "https://localise.biz/api/export/all?#{query}"
|
8
8
|
|
9
|
-
LocaliseRails.logger.info('
|
9
|
+
LocaliseRails.logger.info('LocaliseRails: start getting locales from localise')
|
10
10
|
response = HTTParty.get(uri, headers: headers)
|
11
11
|
|
12
12
|
if response.success?
|
13
|
-
LocaliseRails.logger.info('
|
14
|
-
LocaliseRails.config.redis.set(LocaliseRails::DATA_CACHE_KEY, response.
|
13
|
+
LocaliseRails.logger.info('LocaliseRails: locales got successfully')
|
14
|
+
LocaliseRails.config.redis.set(LocaliseRails::DATA_CACHE_KEY, response.parsed_response.to_json)
|
15
15
|
LocaliseRails.config.redis.set(LocaliseRails::UPDATED_AT_CACHE_KEY, Time.current.to_i)
|
16
16
|
else
|
17
|
-
LocaliseRails.logger.error "Something went wrong downloading translations: #{response.parsed_response}"
|
17
|
+
LocaliseRails.logger.error "LocaliseRails: Something went wrong downloading translations: #{response.parsed_response}"
|
18
18
|
end
|
19
19
|
rescue StandardError => e
|
20
20
|
LocaliseRails.logger.error("LocaliseRails: #{e.message}")
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: localise_rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Osman Baliev
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-04-
|
11
|
+
date: 2022-04-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|