Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomasz Zarna2013-08-23 11:28:44 -0400
committerGerrit Code Review @ Eclipse.org2013-08-23 12:39:08 -0400
commiteca01884c8c6ecbaf2d3104d896cac846f0ef256 (patch)
treea64eec1fa9fa98ba6a21057bbcee64819efedf4b /org.eclipse.mylyn.bugzilla.core/src
parente7fe0a9a130215f70da651ace0d21640d9a93e25 (diff)
downloadorg.eclipse.mylyn.tasks-eca01884c8c6ecbaf2d3104d896cac846f0ef256.tar.gz
org.eclipse.mylyn.tasks-eca01884c8c6ecbaf2d3104d896cac846f0ef256.tar.xz
org.eclipse.mylyn.tasks-eca01884c8c6ecbaf2d3104d896cac846f0ef256.zip
415263: NPE initializing Bugzilla 4.x task data with product absent from
local configuration -- tests Change-Id: I75b669a155b7e0f8536c93a3365807061d206fe5 Task-Url: https://bugs.eclipse.org/bugs/show_bug.cgi?id=415263 Signed-off-by: Tomasz Zarna <tomasz.zarna@tasktop.com>
Diffstat (limited to 'org.eclipse.mylyn.bugzilla.core/src')
-rw-r--r--org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/RepositoryConfiguration.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/RepositoryConfiguration.java b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/RepositoryConfiguration.java
index 000f1c1b7..c06f7bb9b 100644
--- a/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/RepositoryConfiguration.java
+++ b/org.eclipse.mylyn.bugzilla.core/src/org/eclipse/mylyn/internal/bugzilla/core/RepositoryConfiguration.java
@@ -22,6 +22,7 @@ import java.util.List;
import java.util.Locale;
import java.util.Map;
+import org.apache.commons.lang.BooleanUtils;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.mylyn.internal.bugzilla.core.IBugzillaConstants.BUGZILLA_REPORT_STATUS;
@@ -1270,8 +1271,8 @@ public class RepositoryConfiguration implements Serializable {
public boolean getUnconfirmedAllowed(String product) {
ProductEntry entry = products.get(product);
- if (entry != null && entry.getUnconfirmedAllowed() != null) {
- return entry.getUnconfirmedAllowed().booleanValue();
+ if (entry != null) {
+ return BooleanUtils.toBoolean(entry.getUnconfirmedAllowed());
} else {
return false;
}

Back to the top