Avoid empty check of BatchWrite in the caller side

Change-Id: I5672b2d6fab719ab9a5c642a942bf4a6191e808d
diff --git a/core/net/src/main/java/org/onosproject/net/intent/impl/IntentManager.java b/core/net/src/main/java/org/onosproject/net/intent/impl/IntentManager.java
index 8abddf2..69f6e45 100644
--- a/core/net/src/main/java/org/onosproject/net/intent/impl/IntentManager.java
+++ b/core/net/src/main/java/org/onosproject/net/intent/impl/IntentManager.java
@@ -1151,7 +1151,7 @@
 
                 // Write batch information
                 BatchWrite batchWrite = createBatchWrite(updates);
-                writeBatch(batchWrite);
+                store.batchWrite(batchWrite);
 
                 new IntentBatchApplyFirst(ops, processIntentUpdates(updates), endTime, 0, null).run();
             } catch (Exception e) {
@@ -1200,9 +1200,7 @@
         }
 
         protected void writeBatch(BatchWrite batchWrite) {
-            if (!batchWrite.isEmpty()) {
-                store.batchWrite(batchWrite);
-            }
+            store.batchWrite(batchWrite);
         }
     }
 
@@ -1242,7 +1240,7 @@
                 // there are no flow rule batches; finalize the intent update
                 BatchWrite batchWrite = createFinalizedBatchWrite(updates);
 
-                writeBatch(batchWrite);
+                store.batchWrite(batchWrite);
                 return null;
             }
         }