AdvancedCustomFields / AdvancedCustomFields/acf

$field['parent'] inconsistent

Open
#574 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
PHP
Stars
945
Forks
197
PR merge metrics
No merged PRs in 30d

Description

While debugging some issues we got after upgrading to ACF 5.11, I've noticed that on a acf/load_field filter, the $field['parent'] value was the $post->ID of the acf-field-group. When it wasn't in the database, but loaded via JSON, it would return group_5f589cc867a94.

This behaviour should be the same regardless of what methods are used for storing the fields.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the acf/load_field filter and reproduce the issue with a field group stored in the database and one loaded via JSON. Compare the resulting $field['parent'] values; the work is done when both storage methods provide the same parent representation.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.