fix findbugs warning

This commit is contained in:
Athou
2016-10-05 09:01:26 +02:00
parent a37e6a3f4c
commit e57976be99

View File

@@ -13,7 +13,6 @@ import javax.inject.Inject;
import javax.inject.Singleton; import javax.inject.Singleton;
import org.apache.commons.codec.digest.DigestUtils; import org.apache.commons.codec.digest.DigestUtils;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.time.DateUtils; import org.apache.commons.lang3.time.DateUtils;
import org.hibernate.SessionFactory; import org.hibernate.SessionFactory;
@@ -135,9 +134,7 @@ public class FeedRefreshUpdater implements Managed {
if (subscriptions == null) { if (subscriptions == null) {
feed.setMessage("No new entries found"); feed.setMessage("No new entries found");
} } else if (!subscriptions.isEmpty()) {
if (CollectionUtils.isNotEmpty(subscriptions)) {
List<User> users = subscriptions.stream().map(s -> s.getUser()).collect(Collectors.toList()); List<User> users = subscriptions.stream().map(s -> s.getUser()).collect(Collectors.toList());
cache.invalidateUnreadCount(subscriptions.toArray(new FeedSubscription[0])); cache.invalidateUnreadCount(subscriptions.toArray(new FeedSubscription[0]));
cache.invalidateUserRootCategory(users.toArray(new User[0])); cache.invalidateUserRootCategory(users.toArray(new User[0]));