File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
clients_schema_to_openapi/src Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -47,10 +47,10 @@ pub fn add_endpoint(
4747 }
4848
4949 // Namespace
50- // let namespace = match endpoint.name.split_once('.') {
51- // Some((ns, _)) => ns,
52- // None => "core" ,
53- // };
50+ let namespace = match endpoint. name . split_once ( '.' ) {
51+ Some ( ( ns, _) ) => ns,
52+ None => & endpoint . name ,
53+ } ;
5454
5555 // Will we produce multiple paths? If true, we will register components for reuse across paths
5656 let is_multipath = endpoint. urls . len ( ) > 1 || endpoint. urls . iter ( ) . any ( |u| u. methods . len ( ) > 1 ) ;
@@ -196,7 +196,7 @@ pub fn add_endpoint(
196196
197197 // Create the operation, it will be repeated if we have several methods
198198 let operation = openapiv3:: Operation {
199- tags : vec ! [ endpoint . name . splitn ( 1 , '.' ) ] ,
199+ tags : vec ! [ namespace . to_string ( ) ] ,
200200 summary : sum_desc. summary ,
201201 description : sum_desc. description ,
202202 external_docs : tac. convert_external_docs ( endpoint) ,
You can’t perform that action at this time.
0 commit comments