The alter_xx hooks introduced in current CVS version actually break the views module in the 4.7 branch.
For example
$table_data = module_invoke_all('views_tables');
// allow modules to alter the definitions supplied others
$table_data = module_invoke_all('views_tables_alter', $table_data);
leads to $table_data being empty after the call to 'views_tables_alter' hook. Same holds for arguments.
In the end, no default view is working and the views admin screens are a mess :-(
I'm not sure what is intended, but either you pass $table_data by reference to the hook functions, than code looks like this:
$table_data = module_invoke_all('views_tables');
// allow modules to alter the definitions supplied others
module_invoke_all('views_tables_alter', $table_data);
Or you merge the results:
$table_data = module_invoke_all('views_tables');
// allow modules to alter the definitions supplied others
$table_data = array_merge($table_data, module_invoke_all('views_tables_alter', $table_data));
But I can't imagine how the current code can possibly work.
Comments
Comment #1
merlinofchaos commentedYou're absolutely correct. Le sigh. Should've known better than to commit this patch. Will fix before a release goes out.
Comment #2
drewish commentedi'm having the same problem with HEAD...
Comment #3
merlinofchaos commentedPatch reverted in both HEAD and 4.7 branches.
Comment #4
drewish commentedmerlin, thanks for such a quick response.
Comment #5
gerd riesselmann commentedThanks from me, too.