Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jpmckinney’s picture

A summary from that other issue:

The magical drupal_unpack() thing is really weird and messes up the namespace pretty badly. (I can only imagine what happens at the moment if someone tries to put something in $account->data['roles'], for example.)

Looks like drupal_unpack() is also used a couple times by comment module to "unpack" $user->data into the $comment object...

Note that $comment->data is the comment author's $user->data.

catch’s picture

Status: Active » Needs review
FileSize
4.99 KB

Here's a patch which removes all calls to drupal_unpack() in core (only used for comments and users). I'm getting odd test failures locally but would like to see what the bot says.

Status: Needs review » Needs work

The last submitted patch, remove_drupal_unpack.patch, failed testing.

catch’s picture

Status: Needs work » Needs review
FileSize
6.34 KB

Fixed contact tests, the rest must be my crufty HEAD install.

catch’s picture

Oh and just to be clear, the patch doesn't actually remove drupal_unpack(), but we could if we wanted to since it's just dead code now.

chx’s picture

Status: Needs review » Reviewed & tested by the community

That's nice. Thanks for cleaning out old cruft.

Dries’s picture

Status: Reviewed & tested by the community » Fixed

Committed to CVS HEAD. Thanks
.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.