Download & Extend

Unnecessary prefix on field 'add more' $form element

Project:Drupal core
Version:7.x-dev
Component:field system
Category:task
Priority:minor
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

Pointed by sun while discussing #626354: Remove #process pattern from number field:
We don't need to prefix the key of the 'add more' button in the $form structure - basically:

-      $form_element[$field_name . '_add_more'] = array(
+      $form_element['add_more'] = array(

Unneeded cruft, the #name property already contains all the info needed to differentiate between the several buttons in the page.
AttachmentSizeStatusTest resultOperations
field_rename_add_more.patch1.65 KBIdlePassed: 14701 passes, 0 fails, 0 exceptionsView details

Comments

#1

Component:simpletest.module» field system

Doh, FF preselected a wrong component for me...

#2

Status:needs review» reviewed & tested by the community

No, that's Dreditor :) It stores the last selected component for each project. ;)

Can you roll patches with diff -up, please, so we can see the context of the changes? :)

#3

ach - I new I started seeing this at some point, but did not connect with dreditor.

diff -up: I know, sorry, Eclipse patches here :-(

#4

Status:reviewed & tested by the community» fixed

Committed to CVS HEAD. Thanks!

#5

Status:fixed» closed (fixed)

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