Add safety check to _civicrm_api3_deprecation_check