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

@exceptionless/fetchclient

Package Overview
Dependencies
Maintainers
0
Versions
24
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@exceptionless/fetchclient - npm Package Compare versions

Comparing version 0.27.0 to 0.28.0

types/deps/jsr.io/@std/internal/1.0.4/assertion_state.d.ts.map

2

esm/src/FetchClient.js

@@ -432,3 +432,3 @@ import { Counter } from "./Counter.js";

}
if (response.ok) {
if (response.ok || options?.shouldThrowOnUnexpectedStatusCodes === false) {
return;

@@ -435,0 +435,0 @@ }

{
"name": "@exceptionless/fetchclient",
"version": "0.27.0",
"version": "0.28.0",
"description": "A simple fetch client with middleware support for Deno and the browser.",

@@ -5,0 +5,0 @@ "keywords": [

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.setRequestOptions = exports.useMiddleware = exports.setModelValidator = exports.setAccessTokenFunc = exports.setBaseUrl = exports.setCurrentProviderFunc = exports.getCurrentProvider = exports.useFetchClient = void 0;
exports.useFetchClient = useFetchClient;
exports.getCurrentProvider = getCurrentProvider;
exports.setCurrentProviderFunc = setCurrentProviderFunc;
exports.setBaseUrl = setBaseUrl;
exports.setAccessTokenFunc = setAccessTokenFunc;
exports.setModelValidator = setModelValidator;
exports.useMiddleware = useMiddleware;
exports.setRequestOptions = setRequestOptions;
const FetchClientProvider_js_1 = require("./FetchClientProvider.js");

@@ -13,3 +20,2 @@ let getCurrentProviderFunc = () => null;

}
exports.useFetchClient = useFetchClient;
/**

@@ -25,3 +31,2 @@ * Gets the current FetchClientProvider.

}
exports.getCurrentProvider = getCurrentProvider;
/**

@@ -35,3 +40,2 @@ * Sets the function that retrieves the current FetchClientProvider using whatever scoping mechanism is available.

}
exports.setCurrentProviderFunc = setCurrentProviderFunc;
/**

@@ -44,3 +48,2 @@ * Sets the base URL for any FetchClient instances created by the current provider.

}
exports.setBaseUrl = setBaseUrl;
/**

@@ -53,3 +56,2 @@ * Sets the access token function for any FetchClient instances created by the current provider.

}
exports.setAccessTokenFunc = setAccessTokenFunc;
/**

@@ -62,3 +64,2 @@ * Sets the model validator function for any FetchClient instances created by the current provider.

}
exports.setModelValidator = setModelValidator;
/**

@@ -71,3 +72,2 @@ * Adds a middleware to any FetchClient instances created by the current provider.

}
exports.useMiddleware = useMiddleware;
/**

@@ -80,2 +80,1 @@ * Sets the default request options for any FetchClient instances created by the current provider.

}
exports.setRequestOptions = setRequestOptions;

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

}
if (response.ok) {
if (response.ok || options?.shouldThrowOnUnexpectedStatusCodes === false) {
return;

@@ -438,0 +438,0 @@ }

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.parseLinkHeader = void 0;
exports.parseLinkHeader = parseLinkHeader;
const MAX_HEADER_LENGTH = 2000;

@@ -73,2 +73,1 @@ const THROW_ON_MAX_HEADER_LENGTH_EXCEEDED = false;

}
exports.parseLinkHeader = parseLinkHeader;

@@ -15,2 +15,6 @@ import type { CacheKey } from "./FetchClientCache.js";

/**
* By default, the client will throw an error on non-successful and unexpected status codes (outside of 200-299). Use this option to disable that behavior off.
*/
shouldThrowOnUnexpectedStatusCodes?: boolean;
/**
* By default, non-successful status codes (outside of 200-299) will throw an error. Any status code that you wish to

@@ -17,0 +21,0 @@ * handle manually instead of an error being thrown should be included here.

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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