summaryrefslogtreecommitdiff
path: root/lib/oxidized/config/vars.rb
diff options
context:
space:
mode:
authorMatthias Cramer <matthias.cramer@iway.ch>2017-06-16 11:52:47 +0200
committerMatthias Cramer <matthias.cramer@iway.ch>2017-06-16 11:52:47 +0200
commitb7569965d1ec6112d0cd588ebd0b13a541bb6ef7 (patch)
treefbf410ebdfc268e55df73571fc85c426e8b25dbf /lib/oxidized/config/vars.rb
parentbb06ac367daeed2f11682b8ef6e1182923570b42 (diff)
parentdc425ce5bc3143cf4b8322602d7b7521aca37134 (diff)
Merge branch 'master' of https://github.com/ytti/oxidized
Diffstat (limited to 'lib/oxidized/config/vars.rb')
-rw-r--r--lib/oxidized/config/vars.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/oxidized/config/vars.rb b/lib/oxidized/config/vars.rb
index 09f9781..d926ee2 100644
--- a/lib/oxidized/config/vars.rb
+++ b/lib/oxidized/config/vars.rb
@@ -8,8 +8,12 @@ module Oxidized::Config::Vars
r ||= Oxidized.config.groups[@node.group].vars[name.to_s]
end
end
+ if Oxidized.config.models.has_key?(@node.model.class.name.to_s.downcase)
+ if Oxidized.config.models[@node.model.class.name.to_s.downcase].vars.has_key?(name.to_s)
+ r ||= Oxidized.config.models[@node.model.class.name.to_s.downcase].vars[name.to_s]
+ end
+ end
r ||= Oxidized.config.vars[name.to_s] if Oxidized.config.vars.has_key?(name.to_s)
r
end
end
-