Handle undefined variable in ProjectCoreCompatibility.php