Socket
Socket
Sign inDemoInstall

@appsignal/koa

Package Overview
Dependencies
174
Maintainers
8
Versions
33
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.23 to 1.0.24

2

dist/index.js

@@ -11,3 +11,3 @@ "use strict";

install() {
shimmer_1.default.wrap(mod.prototype, "use", patches_1.getKoaUsePatch(tracer));
shimmer_1.default.wrap(mod.prototype, "use", (0, patches_1.getKoaUsePatch)(tracer));
return mod;

@@ -14,0 +14,0 @@ },

@@ -13,2 +13,6 @@ "use strict";

return function use(middlewareFunction) {
if (middlewareFunction.constructor.name == "GeneratorFunction" ||
middlewareFunction.constructor.name == "AsyncGeneratorFunction") {
return original.apply(this, [middlewareFunction]);
}
let patchedFunction;

@@ -15,0 +19,0 @@ if (middlewareFunction.router) {

{
"name": "@appsignal/koa",
"version": "1.0.23",
"version": "1.0.24",
"main": "dist/index",

@@ -5,0 +5,0 @@ "types": "dist/index",

@@ -7,2 +7,4 @@ # `@appsignal/koa`

⚠️ This package is no longer required for AppSignal for Node.js [version 3.0](https://docs.appsignal.com/nodejs/3.x.html). If you use version 3.0 or newer in your app, please remove this package from your `package.json` file.
## Installation

@@ -43,2 +45,4 @@

const app = new Koa();
// Add error handling

@@ -51,6 +55,10 @@

});
const app = new Koa();
```
Note that generator-based middleware was deprecated in Koa version 2.x, and the next major Koa version will remove support for them entirely.
Our instrumentation does not instrument generator-based middleware. The [Koa 2.x migration guide][guide] explains how you can use the `koa-convert` library to convert them to new-style async middleware.
[guide]: https://github.com/koajs/koa/blob/v2.x/docs/migration.md#using-v1x-middleware-in-v2x
## Contributing

@@ -57,0 +65,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc