Merge branch 'stable-3.1' * stable-3.1: Bump Bazel version to 3.0.0 Upgrade bazlets to latest stable-2.16 to build with 2.16.17 API Upgrade bazlets to latest stable-2.16 Change-Id: Ia014786e2946804f4a662c1e5d5d7ddbb9c977ec
diff --git a/BUILD b/BUILD index 35d676e..d5a550f 100644 --- a/BUILD +++ b/BUILD
@@ -1,4 +1,3 @@ -load("@rules_java//java:defs.bzl", "java_library") load("//tools/bzl:junit.bzl", "junit_tests") load( "//tools/bzl:plugin.bzl",
diff --git a/src/main/java/com/googlesource/gerrit/plugins/webhooks/rest/ProjectsCollection.java b/src/main/java/com/googlesource/gerrit/plugins/webhooks/rest/ProjectsCollection.java index a31f99c..5e1d54d 100644 --- a/src/main/java/com/googlesource/gerrit/plugins/webhooks/rest/ProjectsCollection.java +++ b/src/main/java/com/googlesource/gerrit/plugins/webhooks/rest/ProjectsCollection.java
@@ -53,7 +53,7 @@ private ProjectWebhooksResource parse(String id) throws ResourceNotFoundException { Project.NameKey n = Project.nameKey(id); - if (projectCache.get(n) != null) { + if (projectCache.get(n).isPresent()) { return new ProjectWebhooksResource(Project.nameKey(id)); } throw new ResourceNotFoundException(String.format("Project %s does not exist", id));