Fix array_search notice from null array in CRM_Core_Permission::event