@koa/multer
Advanced tools
Comparing version 2.0.2 to 3.0.0
@@ -36,4 +36,4 @@ 'use strict'; | ||
return (ctx, next) => { | ||
return new Promise((resolve, reject) => { | ||
return async (ctx, next) => { | ||
await new Promise((resolve, reject) => { | ||
middleware(ctx.req, ctx.res, err => { | ||
@@ -62,3 +62,5 @@ if (err) return reject(err); | ||
}); | ||
}).then(next); | ||
}); | ||
return next(); | ||
}; | ||
@@ -65,0 +67,0 @@ }; |
{ | ||
"name": "@koa/multer", | ||
"description": "Route middleware for Koa that handles `multipart/form-data` using multer", | ||
"version": "2.0.2", | ||
"author": "Fangdun Cai <cfddream@gmail.com>", | ||
"version": "3.0.0", | ||
"author": { | ||
"name": "Fangdun Cai", | ||
"email": "cfddream@gmail.com" | ||
}, | ||
"bugs": { | ||
@@ -16,3 +19,12 @@ "url": "https://github.com/koajs/multer/issues", | ||
"contributors": [ | ||
"Nick Baugh <niftylettuce@gmail.com> (http://niftylettuce.com/)" | ||
{ | ||
"name": "Nick Baugh", | ||
"email": "niftylettuce@gmail.com", | ||
"url": "http://niftylettuce.com/" | ||
}, | ||
{ | ||
"name": "Imed Jaberi", | ||
"email": "imed_jebari@hotmail.fr", | ||
"url": "https://www.3imed-jaberi.com/" | ||
} | ||
], | ||
@@ -30,3 +42,2 @@ "dependencies": {}, | ||
"husky": "^3.1.0", | ||
"isparta": "^4", | ||
"koa": "^2", | ||
@@ -36,2 +47,3 @@ "lint-staged": "^9.5.0", | ||
"multer": "^1.3.0", | ||
"nyc": "^15.0.0", | ||
"on-finished": "^2", | ||
@@ -45,6 +57,5 @@ "remark-cli": "^7.0.1", | ||
"engines": { | ||
"node": ">= 6" | ||
"node": ">= 8" | ||
}, | ||
"files": [ | ||
"History.md", | ||
"LICENSE", | ||
@@ -110,5 +121,4 @@ "README.md", | ||
"lint": "xo && remark . -qfo", | ||
"test": "npm run lint && mocha --reporter spec --bail --check-leaks", | ||
"test-ci": "npm run lint && isparta cover node_modules/.bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/*.js", | ||
"test-cov": "npm run lint && isparta cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/*.js" | ||
"test": "npm run lint && mocha", | ||
"test-ci": "nyc npm run test --reporter=lcov" | ||
}, | ||
@@ -115,0 +125,0 @@ "xo": { |
@@ -1,2 +0,2 @@ | ||
# [**@koa/multer**](https://github.com/koa/multer) | ||
# [**@koa/multer**](https://github.com/koajs/multer) | ||
@@ -82,5 +82,6 @@ > Route middleware for Koa that handles `multipart/form-data` using [multer][] | ||
| Name | Website | | ||
| -------------- | -------------------------- | | ||
| **Nick Baugh** | <http://niftylettuce.com/> | | ||
| Name | Website | | ||
| --------------- | ------------------------------- | | ||
| **Nick Baugh** | <http://niftylettuce.com/> | | ||
| **Imed Jaberi** | <https://www.3imed-jaberi.com/> | | ||
@@ -87,0 +88,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
8368
55
120