From 4f64d79e15635ba219920cbfaf01cc1fda595f17 Mon Sep 17 00:00:00 2001 From: Thomas Gelf Date: Fri, 6 Nov 2015 09:47:36 +0100 Subject: [PATCH] IcingaConfig: tell whether config would change --- library/Director/IcingaConfig/IcingaConfig.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/library/Director/IcingaConfig/IcingaConfig.php b/library/Director/IcingaConfig/IcingaConfig.php index 8d7aaff0..30b76b39 100644 --- a/library/Director/IcingaConfig/IcingaConfig.php +++ b/library/Director/IcingaConfig/IcingaConfig.php @@ -89,6 +89,12 @@ class IcingaConfig return $config->storeIfModified(); } + public static function wouldChange(DbConnection $connection) + { + $config = new static($connection); + return $config->hasBeenModified(); + } + protected function hasBeenModified() { $this->generateFromDb();