Merge remote-tracking branch 'upstream/4.4' into 4.4-master-2014-01-13-11-57-38
[civicrm-core.git] / api / v3 / UFField.php
index 6751852e147bc6e41997affe11d0356c30ed01b6..72d48e4c1d3731c3913fef7e262d6028a286d4fc 100644 (file)
@@ -77,7 +77,7 @@ function civicrm_api3_uf_field_create($params) {
 
   $fieldId = CRM_Utils_Array::value('id', $params);
   if (!empty($fieldId)) {
-    $UFField = new CRM_core_BAO_UFField();
+    $UFField = new CRM_Core_BAO_UFField();
     $UFField->id = $fieldId;
     if ($UFField->find(TRUE)) {
       $ids['uf_group'] = $UFField->uf_group_id;
@@ -123,6 +123,7 @@ function _civicrm_api3_uf_field_create_spec(&$params) {
     'api.default' => TRUE,
   );
   $params['created_id']['api.default'] = 'user_contact_id';
+  $params['is_active']['api.default'] = TRUE;
 }
 
 /**