@SuppressWarnings("unchecked")
protected ActionForward dispatchMethod(ActionMapping mapping, ActionForm form, HttpServletRequest request,
HttpServletResponse response, String name) throws Exception {
ActionForward actionForward = super.dispatchMethod(mapping, form, request, response, name);
ConfigureExtensionsForm configureExtensionsForm = (ConfigureExtensionsForm) form;
ActionMessages errs = new ActionMessages();
try {
ExtensionStoreDescriptor descriptor = ExtensionStore.getInstance().getDownloadableExtensionStoreDescriptor( request.getParameter("connect") != null ||
Property.getPropertyBoolean(new SystemConfigKey("updates.automaticallyConnectToApplicationStore")));
configureExtensionsForm.setDescriptor(descriptor);
} catch (Exception e) {
errs.add(Globals.ERROR_KEY, new ActionMessage("extensionStore.failedToContactStore", e.getMessage()));
this.saveErrors(request, errs);
}
return actionForward;