[Zope] Help: simple python method goes wrong

Jerome Alet alet@librelogiciel.com
Wed, 5 Jun 2002 11:54:12 +0200


Hi,

On Wed, Jun 05, 2002 at 11:12:47AM +0200, Max M wrote:
> Julian Knight wrote:
> 
> >I have a Python method as follows:
> >
> >
> >results=[]
> >for object in context.objectValues('DTML Document'):
> > results=results.append(object)
> >return results

did I miss something, or the following is ok ?

--- CUT ---
return context.objectValues(['DTML Document'])
--- CUT ---

since objectValues already returns a list...

bye,

Jerome Alet