/* We don't use `next` but need to add it for express.js to
recognize this function as an error handler, hence the
eslint-disable. eslint-disable-next-line no-unused-vars
function renderServerError( err, req, res, next ) {
	if ( process.env.NODE_ENV !== 'production' ) {
		console.error( err );
	}

	const target = getBuildTargetFromRequest( req );

	res.status( err.status || 500 );
	const ctx = {
		urls: generateStaticUrls( target ),
		faviconURL: config( 'favicon_url' ),
	};
	res.send( renderJsx( '500', ctx ) );
}