Skip to content

Commit

Permalink
fix(Express server): Small fix to auth file serving.
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuef committed Oct 12, 2018
1 parent 552f416 commit 3fd593b
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions app/extensions/safe/server-routes/auth.js
Expand Up @@ -20,27 +20,27 @@ const authRoute = {
switch ( linkUrl.path )
{
case '/bundle.js':
res.sendFile( path.resolve( authDist, 'bundle.js' ), { confine: false } );
res.sendFile( path.resolve( authDist, 'bundle.js' ) );
break;
case '/styles.css':
res.sendFile( path.resolve( authDist, 'styles.css' ), { confine: false } );
res.sendFile( path.resolve( authDist, 'styles.css' ) );
break;
case '/bundle.js.map':
res.sendFile( path.resolve( authDist, 'bundle.js.map' ), { confine: false } );
res.sendFile( path.resolve( authDist, 'bundle.js.map' ) );

break;
case '/favicon.png':
res.sendFile( path.resolve( authDist, 'favicon.png' ), { confine: false } );
res.sendFile( path.resolve( authDist, 'favicon.png' ) );
break;
default:
res.sendFile( path.resolve( authDist, 'app.html' ), { confine: false } ).type( 'text/html' );
res.sendFile( path.resolve( authDist, 'app.html' ) );
break;
}
}
catch ( e )
{
logger.error( e );
return res( e.message || e );
return res.send( e.message || e );
}
}
};
Expand Down

0 comments on commit 3fd593b

Please sign in to comment.