grails override redirect controller method
I am trying to override the default controller redirect method and cannot seem to get the following bit of code to work. I have created a plugin and I'm trying to use the "doWithDynamicMethods" to replace the redirect. def doWithDynamicMethods = {ctx -> application.controllerClasses.each() { controllerClass -> replaceRedirectMethod(controllerClass) } } void replaceRedirectMethod(controllerClass) { def oldRedirect = controllerClass.metaClass.pickMethod("redirect", [Map] as Class[]) controllerClass.metaClass.redirect = { Map args, Map params -> // never seems to get here } } Do I have the