Currently Maintenance Helper immediately begins restricting logins when enabled, due to no one initially having the 'login to site' permission.

This is potentially confusing at best, or downtime-inducing at worst (for large production sites utilizing user logins) until the appropriate permissions are set.

I suggest replacing this permission with something like 'login during restricted-access', and adding a variable called 'maintenance_helper_restricted_access' set to 1 if on, 0 if off (which would be a checkbox in the maintenance helper settings).

This would have the desirable effects of making the installation of this module less disruptive, and allowing a simple means to turn this "restricted-access mode" on or off without having to set various permissions on the permissions page.

Comments

greggles’s picture

We could also just grant the permission to everyone when the module is enabled, right? I prefer that solution to this new mode.

greggles’s picture

Having re-read #914236: Add drush support I'm fine with the original proposal here.

claar’s picture

StatusFileSize
new2.09 KB

Added restrict logins mode and permission.

I did not address the issue of users migrating from the old 'login to site' permission to the new 'login during restricted logins' permission.

I see at least two possibilities:

  1. Do nothing. This will mean any Roles previously configured to not be able to login, will now be able to login.
  2. On upgrade, grant the 'login during restricted logins' permission to Roles with the 'login to site' permission, and enable the Restrict Logins mode. I don't even know if this is possible to do.

I suggest the first option, with a warning message on the project page. We could consider up'ing the version number to 6.x-2.x, but since only 15 sites are reported to have this module installed, I propose not overly complicating things.

greggles’s picture

I like "do nothing" and, as you say, we can just make this the 6.x-2.x version and document the change in some release notes.

I'm not sure about "login during restrict-logins" maybe "login during restricted logins" would make more sense than the use of a hyphen to denote a phrase?

claar’s picture

Status: Active » Needs review
StatusFileSize
new2.25 KB

Changed wording to match greggle's #4.

claar’s picture

Assigned: claar » Unassigned
Status: Needs review » Active

Committed to 6.x-2.x -- leaving this issue open until the release notes are figured out.

claar’s picture

Status: Active » Fixed

Changes documented in changelog and project page.

Status: Fixed » Closed (fixed)
Issue tags: -maintenance mode, -restricted access

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