cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ilgro...@apache.org
Subject [2/3] cxf git commit: Fixing behavior with subresources and newer Swagger UI
Date Fri, 23 Sep 2016 11:40:33 GMT
Fixing behavior with subresources and newer Swagger UI


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/f24ad797
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/f24ad797
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/f24ad797

Branch: refs/heads/master
Commit: f24ad79787ec011771b5ad40277e64e202895797
Parents: 7a5e269
Author: Francesco Chicchiriccò <ilgrosso@apache.org>
Authored: Fri Sep 23 13:38:59 2016 +0200
Committer: Francesco Chicchiriccò <ilgrosso@apache.org>
Committed: Fri Sep 23 13:39:18 2016 +0200

----------------------------------------------------------------------
 .../org/apache/cxf/jaxrs/swagger/DefaultSwagger2Serializers.java  | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/f24ad797/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/DefaultSwagger2Serializers.java
----------------------------------------------------------------------
diff --git a/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/DefaultSwagger2Serializers.java
b/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/DefaultSwagger2Serializers.java
index ec52215..194a49e 100644
--- a/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/DefaultSwagger2Serializers.java
+++ b/rt/rs/description-swagger/src/main/java/org/apache/cxf/jaxrs/swagger/DefaultSwagger2Serializers.java
@@ -106,8 +106,7 @@ public class DefaultSwagger2Serializers extends SwaggerSerializers implements
Sw
                     ClassResourceInfo cri = operations.get(entry.getKey());
 
                     tag = new Tag();
-                    String tagName = StringUtils.removeStart(cri.getURITemplate().getValue(),
"/");
-                    tag.setName(StringUtils.isEmpty(tagName) ? "_" : tagName);
+                    tag.setName(cri.getURITemplate().getValue().replaceAll("/", "_"));
                     if (javadocProvider != null) {
                         tag.setDescription(javadocProvider.getClassDoc(cri));
                     }


Mime
View raw message