Hi
I love those module and i never got a problem on d6 versions.
I tried today for the first time D7 and so i wanted to test immediatly masquerade !
I get an error i never occured before on D6 :
When i enter "a" in the search field, autocompletion works and i get an Anonymous choice, but if i choose it and i valid, i get this warning :
User anonymous does not exist. Please enter a valid username.
and i cant' masquerade in Anonymous

CommentFileSizeAuthor
#6 1105696-masq-anonym.patch831 bytesandypost
#4 anonymous_user-1105696-4541658.patch879 bytesAnonymous (not verified)
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

andypost’s picture

Version: 7.x-1.0-rc3 » 7.x-1.x-dev
Status: Active » Postponed (maintainer needs more info)

describe a control which gives you this error? block, menu, user profile

timos’s picture

Hi,
I get this error with an autocompletion field for masquerade in a block.

Anonymous’s picture

Getting this same issue.

Enter "Anonymous" in the Masquerade block switcher - autocomplete works fine but when you submit the form, it returns the error: "User Anonymous does not exist. Please enter a valid username."

This is a fresh Drupal 7 install.

Anonymous’s picture

I did some further testing and it seems like this is the cause:

if ($name == variable_get('anonymous', t('Anonymous'))) {
  $name = '';
}

With that block commented out, the code works fine, from my testing. I hope this is OK - it's my first patch. Let me know if I'm stepping on toes! :)

andypost’s picture

Status: Postponed (maintainer needs more info) » Needs work

Make sense, actually this hunk should be removed because Anonimous name is changed to '' at _masquarade_user_load()

Not sure about alt_login module but this hunk should be removed

andypost’s picture

Status: Needs work » Needs review
FileSize
831 bytes

Going to commit this patch which also adds a trim() for field value

andypost’s picture

RC-4 blocker

andypost’s picture

Status: Needs review » Fixed

Thanx, fixed

Status: Fixed » Closed (fixed)

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

  • Commit 1c0cfac on 7.x-1.x, 8.x-2.x, 8.x-2.x-admin-menu, 8.x-1.x-1836516 by andypost:
    Issue #1105696 by toddmbloom and andypost: Fix anonymous user login in...

  • Commit 1c0cfac on 7.x-1.x, 8.x-2.x, 8.x-2.x-admin-menu, 8.x-1.x-1836516 by andypost:
    Issue #1105696 by toddmbloom and andypost: Fix anonymous user login in...