Issue #2946886 by Deepthi kumari: Remove usage of deprecated create_function() calls for PHP 7.2+ future proofing