commit | 54b345167f0b27c2186624fbe9740f4b4b1bdfed | [log] [tgz] |
---|---|---|
author | Rafal Szalecki <r.szalecki@samsung.com> | Wed Jan 25 10:39:01 2017 +0100 |
committer | Yuta HIGUCHI <y-higuchi@onlab.us> | Wed Jan 25 14:07:00 2017 +0000 |
tree | adeee63c88c1239301950bab4ae7b3776c1ef952 | |
parent | 9b1a45be12f7bb6007db4d1b126d4ba931d04276 [diff] |
[ONOS-5904] Fixed throwing an exception after creating it. Change-Id: I4845d2cb953826a3b6e4a345bfd4d2228b941664
diff --git a/apps/vtn/vtnweb/src/main/java/org/onosproject/vtnweb/resources/RouterWebResource.java b/apps/vtn/vtnweb/src/main/java/org/onosproject/vtnweb/resources/RouterWebResource.java index 332bd41..e78bf56 100644 --- a/apps/vtn/vtnweb/src/main/java/org/onosproject/vtnweb/resources/RouterWebResource.java +++ b/apps/vtn/vtnweb/src/main/java/org/onosproject/vtnweb/resources/RouterWebResource.java
@@ -299,7 +299,7 @@ checkNotNull(routerNode, JSON_NOT_NULL); Map<RouterId, Router> subMap = new HashMap<RouterId, Router>(); if (!routerNode.hasNonNull("id")) { - new IllegalArgumentException("id should not be null"); + throw new IllegalArgumentException("id should not be null"); } else if (routerNode.get("id").asText().isEmpty()) { throw new IllegalArgumentException("id should not be empty"); }