catarse_settings_db 0.0.2 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/models/catarse_settings_db/setting.rb +5 -1
- data/lib/catarse_settings_db/version.rb +1 -1
- metadata +2 -3
- data/README.rdoc +0 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a6b0f2663d0d8d2fea321297cafaf80e438899a5
|
4
|
+
data.tar.gz: 3304a521bc151c66076ac0632b484c4682879a62
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d46bdd69f186efdb7ca9818cf8b2cd2ddececc8167445945380a9b846dd390b73a2126b7b6f39482c87de23b14cfab8af8806e429ae00fed78e206f98ae76f03
|
7
|
+
data.tar.gz: fd5e0a9cfee4e840e380e8d6b5eee1a31b2ee4953539797365ea17c9f3da88f3951be77a52dc96a443c703d1e959fa0ca6d19a1d4cdfbd88175ea8e726bfb739
|
@@ -21,10 +21,14 @@ module CatarseSettingsDb
|
|
21
21
|
set key, value
|
22
22
|
end
|
23
23
|
|
24
|
+
def get_without_cache(key)
|
25
|
+
find_by_name(key).value rescue nil
|
26
|
+
end
|
27
|
+
|
24
28
|
private
|
25
29
|
def get key
|
26
30
|
Rails.cache.fetch("/configurations/#{key}") do
|
27
|
-
|
31
|
+
get_without_cache(key)
|
28
32
|
end
|
29
33
|
end
|
30
34
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: catarse_settings_db
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Antônio Roberto Silva
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2014-
|
12
|
+
date: 2014-09-18 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rails
|
@@ -91,7 +91,6 @@ extensions: []
|
|
91
91
|
extra_rdoc_files: []
|
92
92
|
files:
|
93
93
|
- MIT-LICENSE
|
94
|
-
- README.rdoc
|
95
94
|
- Rakefile
|
96
95
|
- app/models/catarse_settings_db/setting.rb
|
97
96
|
- config/initializers/catarse_settings_db.rb
|
data/README.rdoc
DELETED