Avoid exceptions if the subscription service is disabled

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@28942 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Florian Mü
2011-07-12 11:40:59 +00:00
parent df033727ad
commit 2ebe76a72d

View File

@@ -117,11 +117,13 @@ public class UserFeedRetrieverWebScript extends DeclarativeWebScript
Set<String> userFilter = null;
if ((onlyFollowingStr != null) && (onlyFollowingStr.equalsIgnoreCase("true") || onlyFollowingStr.equalsIgnoreCase("t")))
{
PagingFollowingResults following = subscriptionService.getFollowing(AuthenticationUtil.getRunAsUser(), new PagingRequest(-1, null));
if (following.getPage() != null)
{
userFilter = new HashSet<String>();
userFilter.addAll(following.getPage());
userFilter = new HashSet<String>();
if (subscriptionService.isActive()) {
PagingFollowingResults following = subscriptionService.getFollowing(AuthenticationUtil.getRunAsUser(), new PagingRequest(-1, null));
if (following.getPage() != null)
{
userFilter.addAll(following.getPage());
}
}
}