Comparing version 0.3.4 to 0.3.5
{ | ||
"name": "nestia", | ||
"version": "0.3.4", | ||
"version": "0.3.5", | ||
"description": "Automatic SDK and Document generator for the NestJS", | ||
@@ -5,0 +5,0 @@ "main": "src/index.ts", |
@@ -67,7 +67,12 @@ /** | ||
//---- | ||
// URL SPECIFICATION | ||
if (connection.host[connection.host.length - 1] !== "/" && path[0] !== "/") | ||
path = "/" + path; | ||
if (connection.path) | ||
path = connection.path(path); | ||
const url: URL = new URL(`${connection.host}${path}`); | ||
// DO FETCH | ||
if (connection.enforcePath) | ||
path = connection.enforcePath; | ||
const response: Response = await fetch(`${connection.host}${path}`, init); | ||
const response: Response = await fetch(url.href, init); | ||
let content: string = await response.text(); | ||
@@ -74,0 +79,0 @@ |
@@ -11,3 +11,3 @@ /** | ||
encryption?: IConnection.IEncyptionPassword | IConnection.EncryptionClosure; | ||
enforcePath?: string; | ||
path?: (path: string) => string; | ||
} | ||
@@ -14,0 +14,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
79716
1588