rjq-api-koa
Advanced tools
Comparing version 1.0.3 to 2.0.0
@@ -1,2 +0,1 @@ | ||
const assert = require('assert') | ||
const Koa = require('koa') | ||
@@ -7,7 +6,8 @@ const Router = require('koa-router') | ||
module.exports = function (path, options) { | ||
module.exports = function ({path = '/rjq-api', connection, queues} = {}) { | ||
const app = new Koa() | ||
const router = new Router() | ||
assert(path, 'missing route path') | ||
const api = rjqApi(options) | ||
const api = rjqApi({ | ||
queues, connection | ||
}) | ||
router | ||
@@ -14,0 +14,0 @@ .get('/', function (ctx) { |
{ | ||
"name": "rjq-api-koa", | ||
"version": "1.0.3", | ||
"version": "2.0.0", | ||
"description": "Koa middleware for rjq-api", | ||
@@ -13,3 +13,3 @@ "main": "index.js", | ||
"koa-router": "^7.1.1", | ||
"rjq-api": "^1.0.0" | ||
"rjq-api": "^1.2.1" | ||
}, | ||
@@ -16,0 +16,0 @@ "devDependencies": { |
Sorry, the diff of this file is not supported yet
40327
Updatedrjq-api@^1.2.1