Closed (fixed)
Project:
Views UI: Edit Basic Settings
Version:
7.x-1.0
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Anonymous (not verified)
Created:
6 Mar 2011 at 00:37 UTC
Updated:
7 Feb 2023 at 12:31 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
ap commentedI'm having the same problem.
This function is the culprit. The variable $paths is undefined when the "if" evaluates to false.
Not sure if $paths should be initialized to FALSE or array().
But it seems like it's not that important. I've done a grep over my entire Drupal installation and this function nowhere called. I've added a line to initialize the $paths variable. I've used this as a stopgap measure to eliminate the warnings. THIS IS NOT A PERMANENT SOLUTION!!!. I don't know if this function is needed or what ramifications this change may have. But since it is not used anywhere I feel safe for the time being.
Comment #2
Anonymous (not verified) commentedAh, someone who knows about these things! Could you tell me which file to edit and where to paste the edit and I'll use your work around for the moment as well. Many thanks.
Comment #3
ap commentedThe change is in this file at line 60.
.../sites/all/modules/views_ui_basic/views_ui_basic.module
The directory for your installation may differ.
-----
I just noticed that the comment above the function mentions hooks. This means the function may be called from somewhere in such a way that my grep search is not conclusive. I.e. maybe it is called somewhere.
Actually, it just occurred to me how stupid I am. If the function were not called the warning could never occur.
Anyway I made the change and things still work.
Comment #4
Anonymous (not verified) commentedThank you.
Comment #5
cfischer50 commentedLogically, that function needs $paths to be defined BEFORE the condition ... so I think ap did it right. Thanks for posting!
Comment #6
akeemw commentedYup, ap did it right. hook_admin_paths expects an array to be returned.
Comment #7
askibinski commentedthat patch did the trick.
Comment #8
Anonymous (not verified) commentedThanks everyone. Patch works a treat.
Comment #9
beanworks commentedThanks for posting the fix. :)
Any chance it will get into a dev version or the main version any time soon? Or maybe a note on the project page about it for the unwary? :)
Comment #10
sachbearbeiter commentedsubscribe
Comment #11
Jonah Ellison commentedPatch applied to 7.x-1.1 release. Thanks guys.