From ea6676d61a5cfcd34b8e6eea137a1af67e98a518 Mon Sep 17 00:00:00 2001 From: Inal DJAFAR Date: Wed, 30 Jul 2014 17:36:49 +0200 Subject: [PATCH] add variables types in error message of twig_array_merge --- lib/Twig/Extension/Core.php | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/lib/Twig/Extension/Core.php b/lib/Twig/Extension/Core.php index 04a6f23..3092eb8 100644 --- a/lib/Twig/Extension/Core.php +++ b/lib/Twig/Extension/Core.php @@ -672,7 +672,7 @@ function _twig_markup2string(&$value) function twig_array_merge($arr1, $arr2) { if (!is_array($arr1) || !is_array($arr2)) { - throw new Twig_Error_Runtime('The merge filter only works with arrays or hashes.'); + throw new Twig_Error_Runtime(sprintf('The merge filter only works with arrays or hashes; %s and %s given.', gettype($arr1), gettype($arr2))); } return array_merge($arr1, $arr2); -- 1.7.2.5