[imp] patch: ACLs for the rest of us

Chris Hastie lists at oak-wood.co.uk
Sun Feb 9 19:39:19 PST 2003


On Sun, 9 Feb 2003, Chuck Hagenbuch <chuck at horde.org> wrote
>Quoting Brian Keifer <brian at valinor.net>:
>
>> The recent ACL patch to imp/lib/Session.php and
>> imp/config/servers.php.dist
>> works out-of-the-box for Cyrus users, but the rest of us have to add a
>> line to our server config to avoid errors at the login screen.
>>
>> 'acl' => false,
>
>I would *really* prefer that optional features like this simply disabled
>themselves if there wasn't a config line for them (i.e., a simple !empty()
>check); the list of possible paramaters for a server is getting kind of out
>of hand if they're all required.

Whoops, I thought it did. At least I don't see a problem here. Brian, 
any chance of more information on the errors? A quick look through and I 
wonder if you don't present a drop down list of servers, in which case 
this might help:

--- imp/lib/Session.php,v 1.29
+++ imp/lib/Session.php Sun Feb  9 19:30:52 2003
@@ -144,7 +144,7 @@
              } else {
                  $_SESSION['imp']['server'] = $ptr['server'];
                  $_SESSION['imp']['quota'] = $ptr['quota'];
-                $_SESSION['imp']['acl'] = $ptr['acl'];
+                $_SESSION['imp']['acl'] = isset($ptr['acl']) ? $ptr['acl'] : null;
              }

              if ($conf['server']['change_port']) {


A similar change for quota might also be in order.
-- 
Chris Hastie


More information about the imp mailing list