alshabib
Committed by Gerrit Code Review

Only process pending objectives if there are any.

Change-Id: Ibb34dce32e0bfc55b317036130ead2c1babbaeac
......@@ -218,7 +218,8 @@ public class FlowObjectiveManager implements FlowObjectiveService {
}
private void processPendingObjectives(DeviceId deviceId) {
pendingObjectives.get(deviceId).forEach(obj -> {
pendingObjectives.getOrDefault(deviceId,
Collections.emptySet()).forEach(obj -> {
if (obj instanceof NextObjective) {
getDevicePipeliner(deviceId)
.next(Collections.singletonList((NextObjective) obj));
......