directus-transport-safe-run-middleware
Advanced tools
Comparing version 1.0.20 to 1.0.21
import { Transport, TransportMethods, TransportOptions, TransportResponse } from '@directus/sdk'; | ||
import type { Request, Response } from 'express'; | ||
import type { Request } from 'express'; | ||
export default class DirectusTransportSafeRunMiddleware extends Transport { | ||
protected req: Request; | ||
protected res: Response; | ||
constructor(url: string, req: Request, res: Response); | ||
constructor(url: string, req: Request); | ||
protected request<T = any, R = any>(method: TransportMethods, path: string, data?: Record<string, any>, options?: Omit<TransportOptions, 'url'>): Promise<TransportResponse<T, R>>; | ||
} |
@@ -5,6 +5,5 @@ "use strict"; | ||
class DirectusTransportSafeRunMiddleware extends sdk_1.Transport { | ||
constructor(url, req, res) { | ||
constructor(url, req) { | ||
super({ url }); | ||
this.req = req; | ||
this.res = res; | ||
} | ||
@@ -11,0 +10,0 @@ request(method, path, data, options) { |
{ | ||
"name": "directus-transport-safe-run-middleware", | ||
"version": "1.0.20", | ||
"version": "1.0.21", | ||
"description": "A transport for the Directus JavaScript SDK which calls the express endpoints on the same server.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
6525
100