Project

General

Profile

Bug #1352

Members listed as Authors on Main Blog

Added by Matt Gold almost 8 years ago. Updated almost 8 years ago.

Status:
Resolved
Priority name:
Normal
Assignee:
Category name:
WordPress (misc)
Target version:
Start date:
2011-11-15
Due date:
% Done:

0%

Estimated time:

Description

While promoting our community facilitator team to authors on the main blog, I noticed two bits of weirdness:

1. Several regular members were listed as authors instead of subscribers

2. I can't find Scott among the members.

With regard to #1, I demoted the members in question, but I want you to be aware of this in case it happens again. I do need some help with #2

History

#1 Updated by Boone Gorges almost 8 years ago

  • Target version changed from 1.2.5 to Not tracked

1. Several regular members were listed as authors instead of subscribers

I think that at some point long ago someone had added the main blog as a BP group blog, which promoted some members. That problem should be cleared up with recent versions of BP Groupblog. Keep an eye on it, though.

2. I can't find Scott among the members.

A minor BP release changed the setup so that new site members were not given roles on the main blog. You can just add his existing account at Dashboard > Users > Add User

#2 Updated by Matt Gold almost 8 years ago

Thanks re #1.

Re #2, I tried to add Scott, but when I did, I received an alert box saying that he was already a member of the site. When I did another search through the users to try to find him, his name didn't come up.

#3 Updated by Boone Gorges almost 8 years ago

  • Status changed from Assigned to Reporter Feedback

I had a closer look, and it appears that this case uncovers a rather obscure bug in WordPress. Under WPMU, blog 1's database tables were prefixed with wp_1_. Since WP 3.0, they've been prefixed wp_. This prefixing applies also to some usermeta keys, like the _capabilities keys that dictate someone's role on a given site. In most places in WP, some compatibility code has been added to ensure backward compatibility with sites (like ours) that were originally built on WPMU and thus have the old naming schema. But the bit of code that pulls up the user list at Dashboard > Users was not doing it correctly. More precisely, it looks like when Scott was added to blog 1, his caps were set on wp_capabilities rather than wp_1_capabilities, but Dashboard > Users (probably because of some old compatibility code) was looking only for wp_1_capabilities.

I changed the name of this line in his usermeta and it appears to be working properly. http://commons.gc.cuny.edu/wp-admin/users.php?s=scott*&action=-1&new_role&paged=1&action2=-1

#4 Updated by Matt Gold almost 8 years ago

  • Status changed from Reporter Feedback to Resolved

Cool, and interesting! If you wind up submitting a patch to wordpress, can you update this page with a link to the ticket?

#5 Updated by Boone Gorges almost 8 years ago

OK, but I doubt I will. It was pretty easy to figure out enough about the problem to fix it in this case, but to find enough details to reproduce the issue and fix it would take many times longer. Anyway, it's a pretty fine edge case.

Also available in: Atom PDF