Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@flanc/router-json

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@flanc/router-json - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

middleware/body-parser.js

14

index.js
"use strict";
/* istanbul ignore file */
exports.__esModule = true;
Object.defineProperty(exports, "__esModule", { value: true });
exports.register = exports.setupRouter = exports.errorHandler = exports.path = void 0;
var router_commons_1 = require("flanc/router-commons");
var documentation_1 = require("flanc/router-commons/documentation");
var router;
const router_commons_1 = require("flanc/router-commons");
const documentation_1 = require("flanc/router-commons/documentation");
let router;
exports.path = '/jsonapi';

@@ -14,3 +14,3 @@ function printDocumentation(req, res) {

function errorHandler(err, req, res, next) {
if (!req.path.match(new RegExp("^" + exports.path))) {
if (!req.path.match(new RegExp(`^${exports.path}`))) {
next(err);

@@ -38,6 +38,6 @@ return;

responseHeaders: { 'content-type': 'application/json' },
formatError: function (error) { return formatter(error); },
formatResponse: function (response) { return formatter(response); }
formatError: (error) => formatter(error),
formatResponse: (response) => formatter(response),
});
}
exports.register = register;
{
"name": "@flanc/router-json",
"version": "0.0.1",
"version": "0.0.2",
"description": "The openapi router for flanc apis",

@@ -5,0 +5,0 @@ "license": "Apache-2.0",

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc