Jake Vanderwerf
2026-03-08 c19264ac916707096fe294d996a1b7fb85206b34
inc/rest/routes/ContentRoutes.php
@@ -280,8 +280,9 @@
      // Run query
      $query = new WP_Query($args);
      $registrar = Registrar::getInstance(str_replace('-', '_', $this->post_type));
      $this->fields = $registrar->getFields()??[];
      $this->fields = Registrar::getFieldsFor(str_replace('-', '_', $this->post_type));
      $this->taxonomies = $this->getTaxonomies($this->post_type);
      $posts = array_map([$this, 'prepareItem'], $query->posts);
@@ -480,7 +481,7 @@
      $get = [];
      $fields = (empty($fields)) ? $this->fields : $fields;
      $get = $this->getUploadFields($fields);
      error_log('Upload fields: '.print_r($get, true));
      if (!empty($get)) {
         $actualGet = array_map(function($fieldName) {