translateable 0.2.1 → 0.2.2
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 +4 -4
- data/README.md +1 -1
- data/lib/translateable/version.rb +1 -1
- data/lib/translateable.rb +2 -2
- 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: 1059a6090c3c3293f2b2207bd0e5872e372c9b433433c0f01f14ca48e7a6cf62
|
4
|
+
data.tar.gz: c03b8680e50c211713084f0a7997946a7742bd6acb579119ba7e9b95664085a2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4fb7cad691ae0c16bf50cff559faa736cad5c5c27628239af267b86613da3b4c2fa44875a40097dbf46e531d5b5e8690f64706f44cb8f9595e2bef85e3ef893c
|
7
|
+
data.tar.gz: 7ff0bc5d5c6efeed70f3f1d61c8119b8055d17d4ad652f3233a2d2e22bb52ad38d3466fb5b54330f07bff27ff09d45d4662e63ec333efc602d3f8e04df7dfc4b
|
data/README.md
CHANGED
@@ -225,7 +225,7 @@ Refer to the [Postgres documentation](http://www.postgresql.org/docs/9.4/static/
|
|
225
225
|
|
226
226
|
### Troubleshooting
|
227
227
|
|
228
|
-
If you're having problems with `translateable_sanity_check` you can disable those checks vie environment variable `DISABLE_TRANSLATEABLE_SANITY_CHECK=true`
|
228
|
+
If you're having problems with `translateable_sanity_check` due to non-existing database upon loading, you can disable those checks vie environment variable `DISABLE_TRANSLATEABLE_SANITY_CHECK=true` or by specifying `sanity_checks: false`, for example `translateable :title, sanity_checks: false`.
|
229
229
|
|
230
230
|
## TODO
|
231
231
|
|
data/lib/translateable.rb
CHANGED
@@ -12,9 +12,9 @@ module Translateable
|
|
12
12
|
AttributeValue = Struct.new(:locale, :data)
|
13
13
|
|
14
14
|
module ClassMethods
|
15
|
-
def translateable(*attrs)
|
15
|
+
def translateable(*attrs, sanity_checks: true)
|
16
16
|
attrs.each do |attr|
|
17
|
-
translateable_sanity_check(attr)
|
17
|
+
translateable_sanity_check(attr) if sanity_checks
|
18
18
|
define_translateable_methods(attr)
|
19
19
|
end
|
20
20
|
define_translateable_strong_params(*attrs)
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: translateable
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Oleg Antonyan
|
8
8
|
bindir: exe
|
9
9
|
cert_chain: []
|
10
|
-
date: 2025-
|
10
|
+
date: 2025-04-01 00:00:00.000000000 Z
|
11
11
|
dependencies:
|
12
12
|
- !ruby/object:Gem::Dependency
|
13
13
|
name: bundler
|