Problem/Motivation

There are a lot of unused variables in the following files:
/src/FieldOptions.php
/src/Form/FieldConfigCloneForm.php
/src/Form/ConfigMultipleImportForm.php
/src/Form/FieldBulkCloneForm.php
/src/DisplayCloner.php
/src/Controller/FieldGraph.php
/src/Controller/FieldList.php
/src/Controller/FieldReferencesList.php
field_tools.admin.inc

These variables need to be either removed or used in some way.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

Andrii Momotov created an issue. See original summary.

andrii momotov’s picture

I assigned the task myself because I plan to fix this issue and make a Merge Request.
Please do not work on this issue.

andrii momotov’s picture

Assigned: andrii momotov » Unassigned
Status: Active » Needs review

I did not delete those unused variables that have TODO comments next to them, which means that these variables can be used in the future.

Please review MR. Thanks!

vensires made their first commit to this issue’s fork.

vensires’s picture

Took the opportunity and also removed unused namespaces too.

anybody’s picture

Please ensure that this is not being reverted: https://www.drupal.org/project/field_tools/issues/3324488

Looks like this needs an update!

vensires’s picture

Status: Needs review » Needs work

MR now requires conflict resolution anyway so I set it as "Needs work".
As for your last comment @anybody, maybe we should check this ticket after #3324488: Field groups are not copied when cloning display is resolved?

vensires’s picture

Status: Needs work » Needs review

MR fixed. Still have to decide what to do related to #3324488: Field groups are not copied when cloning display.

andrii momotov’s picture

Hi @tedbow @joachim,

Could you please review the MR?

Thanks.

joachim’s picture

Status: Needs review » Needs work

There's no need to change field_tools.admin.inc -- it's dead code. I left it in out of superstition that I've not yet converted everything that was in there to OO code.

andrii momotov’s picture

Status: Needs work » Needs review

Hi @joachim,

I’ve updated the MR where I removed the changes in field_tools.admin.inc according to your comment.
Please review when you have time. Thanks.

andrii momotov’s picture

Status: Needs review » Fixed

Reviewed the MR and merged. Thanks.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.