File tree Expand file tree Collapse file tree 3 files changed +19
-7
lines changed Expand file tree Collapse file tree 3 files changed +19
-7
lines changed Original file line number Diff line number Diff line change 1+ <!DOCTYPE html>
2+ < html lang ="en ">
3+ < head >
4+ < meta charset ="UTF-8 ">
5+ < meta name ="viewport " content ="width=device-width, initial-scale=1.0 ">
6+ < title > Example</ title >
7+ </ head >
8+ < body >
9+ < h1 > It works!</ h1 >
10+ </ body >
11+ </ html >
Original file line number Diff line number Diff line change @@ -315,9 +315,9 @@ const getHandlers = (state) => {
315315 unauthorizedHandler : ( c , req , res ) => res
316316 . status ( 401 )
317317 . send ( { code : 401 , message : 'Please authenticate first. Header example: "Authorization: Bearer token"' } ) ,
318- notImplementedHandler : ( c , req , res ) => res
319- . status ( 404 )
320- . send ( { code : 501 , message : 'No handler registered for operation' } ) ,
318+ // notImplementedHandler: (c, req, res) => res
319+ // .status(404)
320+ // .send({ code: 501, message: 'No handler registered for operation' }),
321321 } ;
322322} ;
323323
Original file line number Diff line number Diff line change @@ -98,7 +98,6 @@ const initOpenapi = async (names, app) => {
9898export default async ( app , _options ) => {
9999 await app . register ( formbody ) ;
100100 setUpStaticAssets ( app ) ;
101- await initOpenapi ( apps , app ) ;
102101
103102 app . get ( '/http-protocol/example' , ( req , res ) => {
104103 res
@@ -145,13 +144,15 @@ export default async (app, _options) => {
145144 } ) ;
146145 } ) ;
147146
148- app . get ( '/http-protocol/removed ' , ( req , res ) => {
149- res . code ( 301 ) . redirect ( '/http-protocol/example' ) ;
150- } ) ;
147+ app . get ( '/http-protocol' , ( req , res ) => res . sendFile ( 'http-protocol/index.html' ) ) ;
148+
149+ app . get ( '/http-protocol/removed' , ( req , res ) => res . code ( 301 ) . redirect ( '/http-protocol/example' ) ) ;
151150
152151 app . get ( '/js-playwright/users-list' , ( req , res ) => res . sendFile ( 'users-list/index.html' ) ) ;
153152
154153 app . get ( '/js-dom-testing-library/users-list' , ( req , res ) => res . sendFile ( 'users-list/index.html' ) ) ;
155154
155+ await initOpenapi ( apps , app ) ;
156+
156157 return app ;
157158} ;
You can’t perform that action at this time.
0 commit comments