$fields_data = $fs->get_data(); $data['fields'] = isset($fields_data['fields']) ? $fields_data['fields'] : array(); $data['type'] = 'none'; $data['fieldset'] = $fieldset; } } else { $fieldset = array_get($data, '_fieldset', Config::get('default_fieldset')); if ($fieldset) { $fs = Statamic_Fieldset::load($fieldset); $fields_data = $fs->get_data(); $data['fields'] = array_get($fields_data, 'fields', array()); $data['fieldset'] = $fieldset; } $data['type'] = 'none'; } if (Slug::isDraft($page)) { $data['slug'] = substr($page, 2); } elseif (Slug::isHidden($page)) { $data['slug'] = substr($page, 1); } else { $data['slug'] = $page; } $data['original_slug'] = $page; } } else { print "NO PATH"; } // We want to respect the Status field, but not run it through Fieldset::render() $data['status'] = $new ? array_get($data, 'fields:status:default', 'live') : $data['status']; unset($data['fields']['status']); // Content