Closed (fixed)
Project:
Finder
Version:
7.x-2.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
27 Dec 2012 at 20:37 UTC
Updated:
2 Jun 2016 at 07:04 UTC
Jump to comment: Most recent
Everytime I edit a field within a Finder, I get this PHP notice added to my log:
Notice: Undefined property: stdClass::$name in finder_ui_field_form() (line 136 of [shortened]/sites/all/modules/finder/modules/finder_ui/includes/field.inc).
Sure enough, the block of code in question has a couple issues in it...
134 $field_item = NULL;
135 foreach ($finder->esetting($element, 'fields') as $field) {
136 if ($field->name == $field_key) {
137 $field_item = $field;
138 break;
139 }
140 }You see that throughout this file. In fact, $field->name is not written anywhere else in the module. It doesn't exist.
This loop, even when fixed, sets a variable that is never referenced again. This block literally does nothing.
Solution: Remove the block of code.
Comments
Comment #1
PaperWeight commentedRemoving the above code solved my issue - thanks for spotting that
Comment #3
danielb commentedremoved