Author: chris.laprun(a)jboss.com
Date: 2010-09-19 14:58:58 -0400 (Sun, 19 Sep 2010)
New Revision: 4244
Modified:
portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java
Log:
- JBEPP-470: account for the fact that there might be a beginning slash in portlet
application name (this is the case with WSRP).
Modified:
portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java
===================================================================
---
portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java 2010-09-19
12:35:50 UTC (rev 4243)
+++
portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java 2010-09-19
18:58:58 UTC (rev 4244)
@@ -253,7 +253,17 @@
{
throw new Exception("Invalid Application Id: [" + id +
"]");
}
- return getApplication(fragments[0], fragments[1]);
+
+ String category = fragments[0];
+ String applicationName = fragments[1];
+
+ // If the application name contained a beginning slash (which can happen with
WSRP), we need to hack around the
+ // hardcoding of portlet id expectations >_<
+ if(fragments.length == 3 && applicationName.length() == 0)
+ {
+ applicationName = "/" + fragments[2];
+ }
+ return getApplication(category, applicationName);
}
public Application getApplication(final String category, final String name) throws
Exception
Show replies by date