Fix types in express-serve-static-core and webpack-dev-middleware

express-serve-static-core had the wrong type for a string indexer.
webpack-dev-middleware tests needed to wrap an argument in an array.
This commit is contained in:
Nathan Shively-Sanders
2017-06-15 16:36:24 -07:00
parent a357d4781a
commit 755c104c94
2 changed files with 2 additions and 2 deletions

View File

@@ -201,7 +201,7 @@ interface Request extends http.IncomingMessage, Express.Request {
header(name: string): string | undefined;
headers: { [key: string]: string | undefined; };
headers: { [key: string]: string | string[]; };
/**
* Check if the given `type(s)` is acceptable, returning

View File

@@ -27,7 +27,7 @@ webpackDevMiddlewareInstance = webpackDevMiddleware(compiler, {
});
const app = express();
app.use(webpackDevMiddlewareInstance);
app.use([webpackDevMiddlewareInstance]);
webpackDevMiddlewareInstance.close();
webpackDevMiddlewareInstance.invalidate();