From b4a17fabb708cda6b484352f0419e6b72912e527 Mon Sep 17 00:00:00 2001 From: Adam Grare Date: Mon, 31 Jul 2017 10:08:00 -0400 Subject: [PATCH] Fix Core Refresher if there is no ems_vmware setting If there is no prototype.ems_refresh setting currently the Ems Refresh Core worker will raise an exception. --- app/models/miq_ems_refresh_core_worker.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/miq_ems_refresh_core_worker.rb b/app/models/miq_ems_refresh_core_worker.rb index 89ce661a7b9..fcc2ea593ab 100644 --- a/app/models/miq_ems_refresh_core_worker.rb +++ b/app/models/miq_ems_refresh_core_worker.rb @@ -6,7 +6,7 @@ class MiqEmsRefreshCoreWorker < MiqWorker self.required_roles = ["ems_inventory"] def self.has_required_role? - return false if Settings.prototype.ems_vmware.update_driven_refresh + return false if Settings.prototype.try(:ems_vmware).try(:update_driven_refresh) super end