From: Fabien Potencier Date: Tue, 30 Sep 2014 17:40:30 +0000 (+0200) Subject: bug #1500 fix inconsistent response from twig_slice (rodnaph) X-Git-Url: http://git.silmor.de/gitweb/?a=commitdiff_plain;h=53b7001342b5c3b9bcb4f2101344c7f31fc6c438;p=web%2Fkonrad%2Ftwig.git bug #1500 fix inconsistent response from twig_slice (rodnaph) This PR was squashed before being merged into the 1.16-dev branch (closes #1500). Discussion ---------- fix inconsistent response from twig_slice twig_slice can return a boolean when slicing a string outside of its bounds and mbstring is not available. this would cause a knock-on error in twig_first/twig_last when calling current() this (as suggested) adds a cast to emulate the behaviour of mb_substr for substr. Commits ------- c740060 fix inconsistent response from twig_slice --- 53b7001342b5c3b9bcb4f2101344c7f31fc6c438