Download & Extend

Incompatible with 'me' aliases

Project:Ubercart Addresses
Version:6.x-1.0
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (won't fix)

Issue Summary

Using the Me Aliases module with uc_addresses causes addresses to not allow users to edit their address.

Comments

#1

I was able to workaround this issue by replacing me aliases with Menu Token. This may not properly work for all users as external links with the /me (or configured path) alias will not work and Menu Token does not provide the same feature.

In my case, all I used me aliases for was to send users to various sections of their user profile from a menu, so replacement only required recreating the menu items. Note: it may be faster to install menu token and change the existing menu paths rather than recreating the menu items.

#2

Status:active» closed (won't fix)

Hi,

I looked at it and it appears to be the error is caused by the Me-module, Drupal core, or even PHP (tested with PHP 5.3). The error happens because the menu system does a call_user_func_array() which will pass all variables by value. Because the me-module wants a reference instead of a value, PHP 5.3 complains about passing variables by value and so refuses to call me_uid_optional_load().
This was the error I got with error reporting on:

warning: Parameter 2 to me_uid_optional_load() expected to be a reference, value given in /Websites/drupal/drupalsites/drupal6/includes/menu.inc on line 408.

Possible fixes:
- Remove the ampersand before $map at line 419 in me.module.
- menu.inc line 408: place an ampersand before $args, so line 408 will be:

$return = call_user_func_array($function, &$args);

The me-module must have a special reason for those ampersands, I don't know.
Anyway, the root of this problem does not lie by Ubercart Addresses, so I marking this issue as "won't fix".