From 6415b27f26c08e3a28de5434649ec1c1f33a229c Mon Sep 17 00:00:00 2001 From: Fabian Jakobs Date: Wed, 6 Apr 2016 09:59:35 +0000 Subject: [PATCH] make sure to always send an error object to raygun --- plugins/c9.error/raygun.connect.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/c9.error/raygun.connect.js b/plugins/c9.error/raygun.connect.js index 922eae90..10c8d183 100644 --- a/plugins/c9.error/raygun.connect.js +++ b/plugins/c9.error/raygun.connect.js @@ -84,6 +84,9 @@ function plugin(options, imports, register) { } function _sendRequest(raygunClient, err, req) { + if (typeof err == "string") + err = new Error(err); + var parsedUrl = url.parse(req.url, false); var ip = req.remoteAddress;