diff --git a/gerrit-httpd/src/main/java/com/google/gerrit/httpd/plugins/HttpPluginServlet.java b/gerrit-httpd/src/main/java/com/google/gerrit/httpd/plugins/HttpPluginServlet.java index aa2e27a601..5fc632dc37 100644 --- a/gerrit-httpd/src/main/java/com/google/gerrit/httpd/plugins/HttpPluginServlet.java +++ b/gerrit-httpd/src/main/java/com/google/gerrit/httpd/plugins/HttpPluginServlet.java @@ -584,7 +584,8 @@ class HttpPluginServlet extends HttpServlet private void sendJsPlugin(Plugin plugin, ResourceKey key, HttpServletRequest req, HttpServletResponse res) throws IOException { File pluginFile = plugin.getSrcFile(); - if (req.getRequestURI().equals(getJsPluginPath(plugin)) && pluginFile.exists()) { + if (req.getRequestURI().endsWith(getJsPluginPath(plugin)) + && pluginFile.exists()) { res.setHeader("Content-Length", Long.toString(pluginFile.length())); res.setContentType("application/javascript"); writeToResponse(res, new FileInputStream(pluginFile));