Browse Source

Not tabs please

pull/1/head
Wes Mason 9 years ago
parent
commit
f7dc659867
No known key found for this signature in database GPG Key ID: 121DB7952C93970C
  1. 24
      app.js

24
app.js

@ -37,12 +37,12 @@ app.get( '/:package', function( req, res, next ){
return fileExists( cacheFile ) return fileExists( cacheFile )
.tap( function( isExists ){ .tap( function( isExists ){
if( !isExists ){ if( !isExists ){
if ( ENABLE_NPM_FAILOVER ) {
res._log.cacheHit = '---';
return fetchAndCacheMetadata( packageName, cacheFile );
} else {
return res.status( 404 ).json( {} );
}
if ( ENABLE_NPM_FAILOVER ) {
res._log.cacheHit = '---';
return fetchAndCacheMetadata( packageName, cacheFile );
} else {
return res.status( 404 ).json( {} );
}
} }
}) })
.then( function( ){ .then( function( ){
@ -65,12 +65,12 @@ app.get( '/:package/-/:tarball', function( req, res, next ){
fileExists( packagePath ) fileExists( packagePath )
.tap( function( isExists ){ .tap( function( isExists ){
if( !isExists ){ if( !isExists ){
if ( ENABLE_NPM_FAILOVER ) {
res._log.cacheHit = '---';
return fetchAndCacheTarball( packageName, version, packagePath );
} else {
return res.status( 404 ).json( {} );
}
if ( ENABLE_NPM_FAILOVER ) {
res._log.cacheHit = '---';
return fetchAndCacheTarball( packageName, version, packagePath );
} else {
return res.status( 404 ).json( {} );
}
} }
}) })
.then( function(){ .then( function(){

Loading…
Cancel
Save