mirror of
https://github.com/silverstripe/silverstripe-fulltextsearch
synced 2024-10-22 12:05:29 +00:00
FIX Replace deprecated create_function with closure
This commit is contained in:
parent
e001b68232
commit
9106371f30
@ -499,7 +499,10 @@ abstract class SearchIndex extends ViewableData
|
||||
*/
|
||||
protected function _getFieldValue($object, $field)
|
||||
{
|
||||
set_error_handler(create_function('$no, $str', 'throw new Exception("HTML Parse Error: ".$str);'), E_ALL);
|
||||
$errorHandler = function ($no, $str) {
|
||||
throw new Exception('HTML Parse Error: ' . $str);
|
||||
};
|
||||
set_error_handler($errorHandler, E_ALL);
|
||||
|
||||
try {
|
||||
foreach ($field['lookup_chain'] as $step) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user