roleProfile.getDocument() != null &&
userProfile != null &&
userProfile.getDocument() != null)
{
Profile tmpProfile = (Profile) roleProfile.clone();
Portlets rolePortlets = tmpProfile.getDocument().getPortlets();
Portlets userPortlets = userProfile.getDocument().getPortlets();
// Handle pane based profile
if (rolePortlets.getPortletsCount() > 0)
{
for (int i = 0; i < rolePortlets.getPortletsCount(); i++)
{
Portlets pane = rolePortlets.getPortlets(i);
pane.setLayout(null);
userPortlets.addPortlets(pane);
if (logger.isDebugEnabled())
{
logger.debug("UserRoleUpdateAction: appended pane: " + pane.getId() + " to user: " + user.getUserName());
}
}
}
// Handle profile with no panes
else