From ab1a53e5fde13d8bcd32ea721592e14fcc9ee875 Mon Sep 17 00:00:00 2001 From: jlgijsbers Date: Sat, 14 Feb 2004 11:27:23 +0000 Subject: [PATCH] Add backwards compatible action handling. git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@2083 57a73879-2fb5-44c3-a270-3262357dd7e2 --- roundup/cgi/client.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/roundup/cgi/client.py b/roundup/cgi/client.py index 7722865..45918b3 100644 --- a/roundup/cgi/client.py +++ b/roundup/cgi/client.py @@ -1,4 +1,4 @@ -# $Id: client.py,v 1.158 2004-02-14 01:17:38 jlgijsbers Exp $ +# $Id: client.py,v 1.159 2004-02-14 11:27:23 jlgijsbers Exp $ """WWW request handler (also used in the stand-alone server). """ @@ -553,7 +553,12 @@ class Client: else: raise ValueError, 'No such action "%s"'%action # call the mapped action - action_klass(self).handle() + try: + action_klass(self).handle() + except TypeError: + # Old way of specifying actions. + getattr(self, action_klass)() + except ValueError, err: self.error_message.append(str(err)) -- 2.30.2