FIX: hook insertExtraFields must return a returnvalue (0,1,-1)

This commit is contained in:
Christophe Battarel 2014-12-12 11:57:20 +01:00
parent d0dc792b3c
commit a1bba472a0

View File

@ -131,6 +131,7 @@ class HookManager
// Define type of hook ('output', 'returnvalue' or 'addreplace'). 'addreplace' should be type for all hooks. 'output' and 'returnvalue' are deprecated.
$hooktype='output';
if (preg_match('/^pdf_/',$method)) $hooktype='returnvalue'; // pdf_xxx except pdf_writelinedesc are returnvalue hooks. When there is 2 hooks of this type, only last one win.
if ($method =='insertExtraFields') $hooktype='returnvalue';
if (in_array(
$method,
array(