[Zope-Coders] Towards 2.6
Shane Hathaway
shane@zope.com
Wed, 16 Oct 2002 14:32:12 -0400
Florent Guillaume wrote:
> Wow, be very careful with that.
>
> A lot of code mixes id and name for users, and assumes they're always
> the same. CMF for instance uses getUserName a *lot* when it should
> really use getId.
>
> I'd love to see it cleaned up but I'm not sure it's that easy.
I'm concerned that the right thing to do is still open for
interpretation. Based solely on the method names, I would guess that a
method called getUserName() should return "Shane Hathaway", while the
method getId() should return something arbitrary like "501". Neither
one is my login name "shane", which should be available through the
nonexistent method getLoginName().
Would it make sense to add getLoginName()?
Shane