Fix checkstyle if-statements must use braces HostTrackerNorthbound
[controller.git] / opendaylight / adsal / northbound / hosttracker / src / main / java / org / opendaylight / controller / hosttracker / northbound / HostTrackerNorthbound.java
index d7579c8..3769cc7 100644 (file)
@@ -83,7 +83,9 @@ public class HostTrackerNorthbound {
 
     @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() {