Repository: cxf Updated Branches: refs/heads/3.1.x-fixes 2d564d063 -> d530fc8b9
[CXF-6960] Minor update to SwaggerUi resource Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/d530fc8b Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/d530fc8b Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/d530fc8b Branch: refs/heads/3.1.x-fixes Commit: d530fc8b961a38aed0406b68980b6515872050ba Parents: 2d564d0 Author: Sergey Beryozkin <[email protected]> Authored: Mon Jul 25 13:49:55 2016 +0300 Committer: Sergey Beryozkin <[email protected]> Committed: Mon Jul 25 13:51:12 2016 +0300 ---------------------------------------------------------------------- .../src/main/release/samples/jax_rs/description_swagger2/pom.xml | 2 +- .../main/java/org/apache/cxf/jaxrs/swagger/Swagger2Feature.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cxf/blob/d530fc8b/distribution/src/main/release/samples/jax_rs/description_swagger2/pom.xml ---------------------------------------------------------------------- diff --git a/distribution/src/main/release/samples/jax_rs/description_swagger2/pom.xml b/distribution/src/main/release/samples/jax_rs/description_swagger2/pom.xml index 8b07887..1cc6f2e 100644 --- a/distribution/src/main/release/samples/jax_rs/description_swagger2/pom.xml +++ b/distribution/src/main/release/samples/jax_rs/description_swagger2/pom.xml @@ -64,7 +64,7 @@ <dependency> <groupId>org.webjars</groupId> <artifactId>swagger-ui</artifactId> - <version>2.1.0</version> + <version>2.1.8-M1</version> </dependency> <dependency> <groupId>org.apache.cxf</groupId> http://git-wip-us.apache.org/repos/asf/cxf/blob/d530fc8b/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/Swagger2Feature.java ---------------------------------------------------------------------- diff --git a/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/Swagger2Feature.java b/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/Swagger2Feature.java index bf6440d..8bc8afa 100644 --- a/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/Swagger2Feature.java +++ b/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/Swagger2Feature.java @@ -279,11 +279,11 @@ public class Swagger2Feature extends AbstractSwaggerFeature { } @Path("api-docs") public static class SwaggerUIService { - private static final String FAVICON_ICO = "favicon.ico"; + private static final String FAVICON = "favicon"; @GET @Path("{resource:.*}") public Response getResource(@Context UriInfo uriInfo, @PathParam("resource") String resourcePath) { - if (FAVICON_ICO.equals(resourcePath)) { + if (resourcePath.contains(FAVICON)) { return Response.status(404).build(); } if (StringUtils.isEmpty(resourcePath) || "/".equals(resourcePath)) {
