From 998eb6acf358124d86cdb77ec23689e8e56747a3 Mon Sep 17 00:00:00 2001 From: uu59 Date: Fri, 18 Jul 2014 13:58:30 +0900 Subject: [PATCH] Fix if fluentd is not installed --- app/models/plugin.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/models/plugin.rb b/app/models/plugin.rb index 97b6a3d..58dccd2 100644 --- a/app/models/plugin.rb +++ b/app/models/plugin.rb @@ -190,7 +190,8 @@ class Plugin end def fluent_gem_path - if Fluentd.instance.fluentd? + # On installed both td-agent and fluentd system, decide which fluent-gem command should be used depend on setup(Fluentd.instance) + if Fluentd.instance && Fluentd.instance.fluentd? return "fluent-gem" # maybe `fluent-gem` command is in the $PATH end