From da6175dd2a55d9a95547d1579ca50f5204885673 Mon Sep 17 00:00:00 2001 From: Jean-Baptiste Vilain Date: Wed, 14 Aug 2013 11:07:33 +0200 Subject: [PATCH] Fixed quality issue --- .../java/org/sonar/plugins/core/issue/IssueHandlers.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/issue/IssueHandlers.java b/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/issue/IssueHandlers.java index 8d972013fcd..1cb74c5f9be 100644 --- a/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/issue/IssueHandlers.java +++ b/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/issue/IssueHandlers.java @@ -116,7 +116,11 @@ public class IssueHandlers implements BatchExtension { @Override public IssueHandler.Context assign(@Nullable String assignee) { - updater.assign(issue, new DefaultUser().setLogin(assignee).setName(assignee), changeContext); + User user = null; + if(assignee != null) { + user = new DefaultUser().setLogin(assignee).setName(assignee); + } + updater.assign(issue, user, changeContext); return this; } -- 2.39.5