If anonymous users are not allowed to enter a registration code, OGUR should not output the og_register fieldset at all.

Due to wrong line endings in CVS, my client seems to be unable to generate a proper patch. (Please fix this, too)

old:

function og_user_roles_form_alter(&$form, $form_state, $form_id) {
  // If this is a registration form, put the Group Register box on it if appropriate.
  // Anonymous users need 'use registration codes' permission
  // 'Allow Registration Codes' in OGUR settings must be checked on.
  if ($form_id == 'user_register') {

new:

function og_user_roles_form_alter(&$form, $form_state, $form_id) {
  // If this is a registration form, put the Group Register box on it if appropriate.
  // Anonymous users need 'use registration codes' permission
  // 'Allow Registration Codes' in OGUR settings must be checked on.
  if ($form_id == 'user_register' && user_access('use registration codes')) {

Comments

somebodysysop’s picture

og_user_roles-DRUPAL-6--1.user-register.patch

What's this for?

sun’s picture

Well, I wanted to supply a proper patch, but as mentioned in the original post:

Due to wrong line endings in CVS, my client seems to be unable to generate a proper patch. (Please fix this, too)

I.e.: Just editing one line in the module file results in this patch file. Don't blame me - I even deleted the checkout, started from scratch, and still got the same result. This is weird. I'm creating a buzz of patches for Drupal a day and never experienced this issue with any other module.

somebodysysop’s picture

I think the editor I use is putting in tabs. On my list of things to do is to go through and get the module up to Drupal standards. If that one line is the only thing that needs to be changed, I should have that done and committed to dev in the next day.

Thanks!

somebodysysop’s picture

Status: Needs review » Fixed

Committed to dev branch.

Status: Fixed » Closed (fixed)

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

johnhanley’s picture

Version: 6.x-1.0 » 5.x-3.7
Status: Closed (fixed) » Active

Same problem exists in 5.x-3.7.

sun’s picture

Status: Active » Patch (to be ported)
dman’s picture

Here's *a* patch, although it includes a comment as I'm working on a production site for someone else and need to notate branches from official releases.

The 'patch' is two words, and is easier to commit by hand.

sun’s picture

Version: 5.x-3.7 » 6.x-1.0
Status: Patch (to be ported) » Closed (fixed)

I don't think that 5.x-3.x will see any further commits. At least it became quite quiet around SomebodySysop since the rewritten OGUR 4.x exists... ;)

Hence, closing this issue.

@SomebodySysop: Would it make sense if I'd take over project ownership?

somebodysysop’s picture

@SomebodySysop: Would it make sense if I'd take over project ownership?

@Sun:

I have been engaged on another project for the past few months which took me away from OGUR. I assumed that folks who needed immediate assistance would use OGUR 4.x. I had no idea whatsoever that you would unilaterally take it upon yourself to either close or mark as "won't fix" OGUR 1.x issues.

Let me make this clear: While I wholeheartedly support the growth of OGUR 4.x, I have no intent whatsoever of abandoning OGUR 1.x and the folks who still use and depend on it. I apologize if my absence from this forum gave anyone that opinion.

As concerns OGUR 1.x issues, I would prefer if you would let me address those myself.