From 750d68009cfebd50bbfd4cf32f9ba7a29143262a Mon Sep 17 00:00:00 2001 From: Lukasz Lenart Date: Wed, 15 Jan 2014 09:12:23 +0100 Subject: [PATCH] WW-4244 Uses ObjectFactory to instantiate action in config-browser --- .../org/apache/struts2/config_browser/ShowConfigAction.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins/config-browser/src/main/java/org/apache/struts2/config_browser/ShowConfigAction.java b/plugins/config-browser/src/main/java/org/apache/struts2/config_browser/ShowConfigAction.java index 1b3b93209..faecb8653 100644 --- a/plugins/config-browser/src/main/java/org/apache/struts2/config_browser/ShowConfigAction.java +++ b/plugins/config-browser/src/main/java/org/apache/struts2/config_browser/ShowConfigAction.java @@ -1,4 +1,5 @@ /* + * $Id: ShowConfigAction.java 1536698 2013-10-29 13:00:58Z lukaszlenart $ * $Id$ * * Licensed to the Apache Software Foundation (ASF) under one @@ -106,8 +107,8 @@ public class ShowConfigAction extends ActionNamesAction { config = configHelper.getActionConfig(namespace, actionName); actionNames = new TreeSet(configHelper.getActionNames(namespace)); try { - Class clazz = objectFactory.getClassInstance(getConfig().getClassName()); - properties = reflectionProvider.getPropertyDescriptors(clazz.newInstance()); + Object action = objectFactory.buildAction(actionName, namespace, config, null); + properties = reflectionProvider.getPropertyDescriptors(action); } catch (Exception e) { LOG.error("Unable to get properties for action " + actionName, e); addActionError("Unable to retrieve action properties: " + e.toString());