} catch (Exception ex) {
log.error(ex.getMessage(), ex);
}
} else if (PORTAL_TAG.equals(element.getTagName()) || PORTLET_TAG.equals(element.getTagName())) {
String resourceName = XMLTools.asString(XMLTools.getUniqueChild(element, "name", true));
ResourceScope resourceScope;
if (PORTLET_TAG.equals(element.getTagName())) {
resourceName = contextPath.substring(1) + "/" + resourceName;
resourceScope = ResourceScope.PORTLET;
} else {
resourceScope = ResourceScope.PORTAL;