Skip api4 when generating api3 docs
authorColeman Watts <coleman@civicrm.org>
Mon, 27 May 2019 16:49:42 +0000 (12:49 -0400)
committerColeman Watts <coleman@civicrm.org>
Mon, 27 May 2019 21:34:39 +0000 (17:34 -0400)
Civi/Test/Api3DocTrait.php

index a4c3ceb565fbe96ab30dbaaeb88d4b9d9bf31ae5..6b3ad189a2b80f8877ef1241f94b2c85a2256c69 100644 (file)
@@ -68,7 +68,7 @@ trait Api3DocTrait {
    *   Name for this example file (CamelCase) - if omitted the action name will be substituted.
    */
   private function documentMe($entity, $action, $params, $result, $testFunction, $testFile, $description = "", $exampleName = NULL) {
-    if (defined('DONT_DOCUMENT_TEST_CONFIG') && DONT_DOCUMENT_TEST_CONFIG) {
+    if ($params['version'] != 3 || (defined('DONT_DOCUMENT_TEST_CONFIG') && DONT_DOCUMENT_TEST_CONFIG)) {
       return;
     }
     $entity = _civicrm_api_get_camel_name($entity);