Fix checkstyle if-statements must use braces ConnectionManagerNorthbound 19/13519/1
authorThanh Ha <thanh.ha@linuxfoundation.org>
Tue, 9 Dec 2014 23:01:44 +0000 (18:01 -0500)
committerThanh Ha <thanh.ha@linuxfoundation.org>
Tue, 9 Dec 2014 23:01:44 +0000 (18:01 -0500)
Change-Id: If429fd24b5b346a350bc1cf488c800d445d4bbc1
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
opendaylight/adsal/northbound/connectionmanager/src/main/java/org/opendaylight/controller/connectionmanager/northbound/ConnectionManagerNorthbound.java

index dde3210928689278af7d7f2e3103b0e78c114b47..3f64b07ab6d61dd52168c16e9f1739590cb5fd27 100644 (file)
@@ -62,7 +62,9 @@ public class ConnectionManagerNorthbound {
     }
     @Context
     public void setSecurityContext(SecurityContext context) {
     }
     @Context
     public void setSecurityContext(SecurityContext context) {
-        if (context != null && context.getUserPrincipal() != null) username = context.getUserPrincipal().getName();
+        if (context != null && context.getUserPrincipal() != null) {
+            username = context.getUserPrincipal().getName();
+        }
     }
     protected String getUserName() {
         return username;
     }
     protected String getUserName() {
         return username;