I am getting the following error on the login page when Securesite is enabled.
Apart from that I don't notice any adverse effect.

warning: array_unshift() [function.array-unshift]: The first argument should be an array in /var/www/drupal/sites/all/modules/logintoboggan/logintoboggan.module on line 191.

CommentFileSizeAuthor
#1 securesite_declare_handlers.patch728 byteshunmonk

Comments

hunmonk’s picture

Title: watchdog error(first argument should be an array) » declare #validate and #submit for consistency
Project: LoginToboggan » Secure Site
Version: 6.x-1.6 » 6.x-2.x-dev
StatusFileSize
new728 bytes

meh, i knew i should have coded more defensively there...

i put in some paranoid checks in LoginToboggan to avoid this issue in the future.

incidentally, that error does break LT's validation handler, which would be a problem if you have 'Login with e-mail' set.

the problem is securesite's implementation of the login form, securesite_user_login(&$form_state). it doesn't declare any #submit or #validate handlers at all in the form.

i would recommend that function be patched to at least include empty arrays for #validate and #submit -- most other modules are probably expecting those to be arrays.

attached patch for the 6.x-2.x branch does this.

hunmonk’s picture

Priority: Minor » Normal
Status: Active » Needs review
skizzo’s picture

Patched. Should this issue be moved to the Secure site queue?

hunmonk’s picture

@skizzo: it's already in the Secure Site queue -- read the metadata table at the top of the issue...

jeffschuler’s picture

I was experiencing this issue with Secure Site 6.x-2.4, and LoginToboggan 6.x-1.6.

The patch in #1 (patching Secure Site 6.x-2.4) worked for me.

Thanks!

joelstein’s picture

Status: Needs review » Needs work

The patch in #1 does get rid of the error, yes. But it did not completely solve the problem for me. I still can only able login with my username, but not my e-mail address (which LoginToboggan allows me to do), which I could do before I enabled Secure Site.

The documentation for securesite_user_login() says the following:

We do not use the default validate and submit functions because we may allow anonymous users.

I also found this issue: #419924: Securesite and Logintoboggan. Are the two modules simply incompatible?