Automattic / Automattic/custom-metadata

Cloning a field clones field contents as well

Open
#103 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
PHP
Stars
190
Forks
46
Avg merge
46m
Merged PRs (30d)
15

Description

When clicking _\+ Add New_ to add a field when `'multiple' => true`, the cloned field's contents are copied into the new field:

![screen shot 2014-02-18 at 8 58 44 pm](https://f.cloud.github.com/assets/605361/2202366/057e81f8-9901-11e3-9517-1e395d0d333f.png)

The expected behaviour (in my mind) would be that a new blank field would be created like so:

![screen shot 2014-02-18 at 8 57 59 pm](https://f.cloud.github.com/assets/605361/2202358/e99c0aaa-9900-11e3-822f-728065444e74.png)

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the issue in the custom-field interface with “multiple” enabled and clicking “+ Add New” to identify the handler that clones the field. Trace how the existing field contents are copied, then verify that the newly added field is blank while the original remains unchanged.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.