File tree 2 files changed +1
-7
lines changed
clients_schema_to_openapi/src 2 files changed +1
-7
lines changed Original file line number Diff line number Diff line change @@ -315,13 +315,8 @@ fn get_path_parameters(template: &str) -> Vec<&str> {
315
315
316
316
fn split_summary_desc ( desc : String ) -> SplitDesc {
317
317
let mut parts = desc. split ( [ '.' , '\n' , ':' ] ) ;
318
- if parts. clone ( ) . count ( ) == 1 {
319
- return SplitDesc {
320
- summary : String :: from ( parts. next ( ) . unwrap ( ) ) ,
321
- description : String :: new ( )
322
- }
323
- }
324
318
let first_line = parts. next ( ) . unwrap_or_else ( || "" ) ;
319
+
325
320
let new_desc = desc. replace ( first_line, "" ) ;
326
321
let trim = new_desc. trim ( ) ;
327
322
let remove_period = trim. strip_prefix ( '.' ) . unwrap_or_else ( || trim) ;
@@ -330,7 +325,6 @@ fn split_summary_desc(desc: String) -> SplitDesc{
330
325
summary : String :: from ( first_line. trim ( ) ) ,
331
326
description : String :: from ( remove_column. trim ( ) )
332
327
}
333
-
334
328
}
335
329
336
330
struct SplitDesc {
You can’t perform that action at this time.
0 commit comments