[icinga-checkins] icinga.org: icingaweb2-module-director/master: PropertyModifierJsonDecode: show substring on fail

git at icinga.org git at icinga.org
Thu Dec 22 12:30:57 CET 2016


Module: icingaweb2-module-director
Branch: master
Commit: 6800d2cbd2e9f164c7f24161d19e556ee3ec7adc
URL:    https://git.icinga.org/?p=icingaweb2-module-director.git;a=commit;h=6800d2cbd2e9f164c7f24161d19e556ee3ec7adc

Author: Thomas Gelf <thomas at gelf.net>
Date:   Thu Dec 22 12:30:22 2016 +0100

PropertyModifierJsonDecode: show substring on fail

---

 library/Director/PropertyModifier/PropertyModifierJsonDecode.php |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/library/Director/PropertyModifier/PropertyModifierJsonDecode.php b/library/Director/PropertyModifier/PropertyModifierJsonDecode.php
index c2fe967..65486e4 100644
--- a/library/Director/PropertyModifier/PropertyModifierJsonDecode.php
+++ b/library/Director/PropertyModifier/PropertyModifierJsonDecode.php
@@ -47,7 +47,7 @@ class PropertyModifierJsonDecode extends PropertyModifierHook
                     throw new InvalidPropertyException(
                         'JSON decoding failed with "%s" for %s',
                         $this->getLastJsonError(),
-                        $value
+                        substr($value, 0, 128)
                     );
             }
         }



More information about the icinga-checkins mailing list