for request.args I can do

request.args(0)

and will return None if there is no such element, much nicer than

request.args[0] if len(request.args)>0 else None

I always wondered why this does not work for request.vars I have the
following all over my code

q = request.vars['q'] if request.vars.has_key('q') else None

did I miss something?


-- 
To unsubscribe, reply using "remove me" as the subject.

Reply via email to