additional fixes
[civicrm-core.git] / Civi / Core / SettingsBag.php
index 9b415dcf433a5e9af1a2e96b592e2226da3cdd58..66a663e93bad56665d78bfdf46f5fd6b42b3759f 100644 (file)
@@ -352,6 +352,10 @@ class SettingsBag {
     }
     $dao->find(TRUE);
 
+    // Call 'on_change' listeners. It would be nice to only fire when there's
+    // a genuine change in the data. However, PHP developers have mixed
+    // expectations about whether 0, '0', '', NULL, and FALSE represent the same
+    // value, so there's no universal way to determine if a change is genuine.
     if (isset($metadata['on_change'])) {
       foreach ($metadata['on_change'] as $callback) {
         call_user_func(