File tree Expand file tree Collapse file tree
core/src/main/java/net/j4c0b3y/api/config Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -302,6 +302,12 @@ private void step(String path) throws ReflectiveOperationException {
302302
303303 // Set the associated comment for the route's block if present.
304304 document .setComment (document .getBlock (route ), field .getAnnotation (Comment .class ));
305+
306+ // Ensure position is forced when structure formatting is enabled.
307+ if (handler .isFormatStructure ()) {
308+ document .move (route , route );
309+ }
310+
305311 continue ;
306312 }
307313
@@ -321,6 +327,12 @@ private void step(String path) throws ReflectiveOperationException {
321327 // If the section exists, and we shouldn't skip, set the comment and recurse.
322328 if (section != null ) {
323329 document .setComment (section , member .getAnnotation (Comment .class ));
330+
331+ // Ensure position is forced when structure formatting is enabled.
332+ if (handler .isFormatStructure ()) {
333+ document .move (route , route );
334+ }
335+
324336 step (route );
325337 }
326338 }
You can’t perform that action at this time.
0 commit comments