Skip to content

Commit

Permalink
feat(koa-router): add support to @koa/router version 10 (#2004)
Browse files Browse the repository at this point in the history
* feat(koa-router): add support to @koa/router version 10

Co-authored-by: Alan Storm <[email protected]>
  • Loading branch information
sibelius and astorm authored Mar 26, 2021
1 parent 5237892 commit c64a089
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .tav.yml
Original file line number Diff line number Diff line change
Expand Up @@ -231,12 +231,12 @@ express-queue:
koa-router:
node: '>=6.0.0'
peerDependencies: koa@2
versions: '>=5.2.0 <10'
versions: '>=5.2.0 <11'
commands: node test/instrumentation/modules/koa-router/old-name.js
'@koa/router':
node: '>=8.0.0'
peerDependencies: koa@2
versions: '>=8 <10'
versions: '>=8 <11'
commands: node test/instrumentation/modules/koa-router/new-name.js

elasticsearch:
Expand Down
2 changes: 1 addition & 1 deletion lib/instrumentation/modules/koa-router.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ var shimmer = require('../shimmer')

module.exports = function (Router, agent, { version, enabled }) {
if (!enabled) return Router
if (!semver.satisfies(version, '>=5.2.0 <10')) {
if (!semver.satisfies(version, '>=5.2.0 <=10')) {
agent.logger.debug('koa-router version %s not supported - aborting...', version)
return Router
}
Expand Down

0 comments on commit c64a089

Please sign in to comment.