[Zope] solved: acl_users

Andreas Jung lists at zopyx.com
Wed Jan 3 15:51:24 EST 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1



- --On 3. Januar 2007 14:42:58 -0600 Sean Duffy <swduffy at unmc.edu> wrote:

> y=context.LoadUsers()
> p=[]
> for x in y:
>   z=x.split(' ')
>   z0=z[0]
>   z1=z[1]
>   z1=z1[:-1]
^^^^^^^^^^^^^^^^^

Don't do that. Python strings have a strip() method.
Especially this code won't work with files with DOS line-endings.

- -aj
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (Darwin)

iD8DBQFFnBdQCJIWIbr9KYwRAnB3AKCkU5D2nAw7oU7/uQ3CTVwTweHAZQCfdSyT
32wmytjeXlyRgSL/2+dlGsU=
=uAn5
-----END PGP SIGNATURE-----



More information about the Zope mailing list