@@ -31,7 +31,11 @@ class API {
31
31
this . _routes = { }
32
32
33
33
// Default callback
34
- this . _cb = function ( ) { console . log ( 'No callback specified' ) }
34
+ this . _cb = function ( ) {
35
+ /* eslint-disable no-console */
36
+ console . log ( 'No callback specified' )
37
+ /* eslint-enable no-console */
38
+ }
35
39
36
40
// Middleware stack
37
41
this . _middleware = [ ]
@@ -172,6 +176,7 @@ class API {
172
176
173
177
let message
174
178
179
+ /* eslint-disable no-console */
175
180
if ( e instanceof Error ) {
176
181
response . status ( this . _errorStatus )
177
182
message = e . message
@@ -180,6 +185,7 @@ class API {
180
185
message = e
181
186
! this . _test && console . log ( 'API Error:' , e )
182
187
}
188
+ /* eslint-enable no-console */
183
189
184
190
// If first time through, process error middleware
185
191
if ( response . _state === 'processing' ) {
@@ -280,7 +286,9 @@ class API {
280
286
try {
281
287
this . _app [ namespace ] = packages [ namespace ]
282
288
} catch ( e ) {
289
+ /* eslint-disable no-console */
283
290
console . error ( e . message )
291
+ /* eslint-enable no-console */
284
292
}
285
293
}
286
294
} else if ( arguments . length === 2 && typeof packages === 'string' ) {
@@ -317,7 +325,9 @@ class API {
317
325
let routes = UTILS . extractRoutes ( this . _routes )
318
326
319
327
if ( format ) {
320
- prettyPrint ( routes )
328
+ /* eslint-disable no-console */
329
+ console . log ( prettyPrint ( routes ) )
330
+ /* eslint-enable no-console */
321
331
} else {
322
332
return routes
323
333
}
0 commit comments