Attached patch resolves.
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | filefield_paths-1187598-3-interdiff.txt | 2.75 KB | brad.bulger |
| #3 | filefield_paths-1187598-3.patch | 3.71 KB | brad.bulger |
| #2 | filefield_paths-1187598-2.patch | 1.84 KB | mikeytown2 |
| #1 | 1187598-filefield_paths-undefined-index.patch | 1.13 KB | mrfelton |
Comments
Comment #1
mrfelton commentedComment #2
mikeytown2 commentedPatch works for me. For search purposes
Notice: Undefined index: #settings in filefield_paths_node_update() (filefield_paths/filefield_paths.module).
Added another fix to this patch
Notice: Undefined index: filename in filefield_paths_token_values() (filefield_paths/filefield_paths.module).
Comment #3
brad.bulger commentedboth of these patches have same problem:
$ffp['#settings'][$file['name']]is not a filename, it's the settings array for a file, keyed by name. if that settings array doesn't exist, that's probably a sign of some other issue, but in any case returning an empty string if it doesn't is inappropriate. i changed it to return an empty array.i also added code to filefield_paths_filefield_paths_process_file() to handle cases when
$settings['filepath']['value']is not defined (for instance, when $settings is an empty array from the above case).a problem that may be related to all this: if hooks for the ImageField module run before Filefield Paths hooks on a system, it causes problems for Filefield Paths, because its hook implementations for imagefield depend on values defined by the filefield_paths implementations - eg
$file['filepath']['old']and such. in theory if both modules have the same weight in the system table, filefield_paths should come first, but that wasn't always proving to be the case. setting imagefield to a higher weight resolved that issue, but the dependency seems like a problem in itself.Comment #4
decipheredIt is very bad practice to add a patch and mark it as 'RTBC' yourself, it is equally bad to add a new patch after the issue is marked as 'RTBC' without setting it back to 'Needs review'. However patches are always appreciated, so don't take that to harshly.
However, I would appreciate it if when updating or re-rolling patches that you include a interdiff so that people are easily able to see what has changed in the latest patch for reviewing processes:
- http://xjm.drupalgardens.com/blog/interdiffs-how-make-them-and-why-they-...
- https://drupal.org/documentation/git/interdiff
And lastly, I'm assigning this to roball as I'm no longer maintaining the Drupal 6 branch of File (Field) Paths.
Cheers,
Deciphered.
Comment #5
brad.bulger commentedah, sorry, i forgot to change the status and assigned to - i had a browser crash the first time i filled this out, before submit, so doing it again i got sloppy.
interdiff is attached.
Comment #6
decipheredNo longer supporting Drupal 6 issues for this module.