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

@aws-sdk/middleware-stack

Package Overview
Dependencies
Maintainers
4
Versions
120
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aws-sdk/middleware-stack - npm Package Compare versions

Comparing version 1.0.0-beta.4 to 1.0.0-gamma.1

2

build/MiddlewareStack.d.ts

@@ -49,4 +49,4 @@ import { InitializeHandlerOptions, BuildHandlerOptions, FinalizeRequestHandlerOptions, MiddlewareType, SerializeMiddleware, FinalizeRequestMiddleware, HandlerExecutionContext, InitializeMiddleware, MiddlewareStack as IMiddlewareStack, SerializeHandlerOptions, DeserializeMiddleware, DeserializeHandlerOptions, DeserializeHandler, Pluggable, BuildMiddleware, Handler, AbsoluteLocation, RelativeLocation } from "@aws-sdk/types";

*/
private geMiddlewareList;
private getMiddlewareList;
resolve<InputType extends Input, OutputType extends Output>(handler: DeserializeHandler<InputType, OutputType>, context: HandlerExecutionContext): Handler<InputType, OutputType>;
}

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

*/
MiddlewareStack.prototype.geMiddlewareList = function () {
MiddlewareStack.prototype.getMiddlewareList = function () {
var middlewareList = [];

@@ -305,3 +305,3 @@ var _a = this.normalizeRelativeEntries(), orphanedRelativeEntries = _a[0], anchors = _a[1];

MiddlewareStack.prototype.resolve = function (handler, context) {
for (var _i = 0, _a = this.geMiddlewareList(); _i < _a.length; _i++) {
for (var _i = 0, _a = this.getMiddlewareList(); _i < _a.length; _i++) {
var middleware = _a[_i];

@@ -327,2 +327,2 @@ handler = middleware(handler, context);

};
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiTWlkZGxld2FyZVN0YWNrLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vc3JjL01pZGRsZXdhcmVTdGFjay50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFvQ0E7SUFBQ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bGV3YXJlTGlzdC5yZXZlcnNlKCk7XG4gIH1cblxuICByZXNvbHZlPElucHV0VHlwZSBleHRlbmRzIElucHV0LCBPdXRwdXRUeXBlIGV4dGVuZHMgT3V0cHV0PihcbiAgICBoYW5kbGVyOiBEZXNlcmlhbGl6ZUhhbmRsZXI8SW5wdXRUeXBlLCBPdXRwdXRUeXBlPixcbiAgICBjb250ZXh0OiBIYW5kbGVyRXhlY3V0aW9uQ29udGV4dFxuICApOiBIYW5kbGVyPElucHV0VHlwZSwgT3V0cHV0VHlwZT4ge1xuICAgIGZvciAoY29uc3QgbWlkZGxld2FyZSBvZiB0aGlzLmdldE1pZGRsZXdhcmVMaXN0KCkpIHtcbiAgICAgIGhhbmRsZXIgPSBtaWRkbGV3YXJlKFxuICAgICAgICBoYW5kbGVyIGFzIEhhbmRsZXI8SW5wdXQsIE91dHB1dFR5cGU+LFxuICAgICAgICBjb250ZXh0XG4gICAgICApIGFzIGFueTtcbiAgICB9XG5cbiAgICByZXR1cm4gaGFuZGxlciBhcyBIYW5kbGVyPElucHV0VHlwZSwgT3V0cHV0VHlwZT47XG4gIH1cbn1cblxuY29uc3Qgc3RlcFdlaWdodHM6IHsgW2tleSBpbiBTdGVwXTogbnVtYmVyIH0gPSB7XG4gIGluaXRpYWxpemU6IDUsXG4gIHNlcmlhbGl6ZTogNCxcbiAgYnVpbGQ6IDMsXG4gIGZpbmFsaXplUmVxdWVzdDogMixcbiAgZGVzZXJpYWxpemU6IDFcbn07XG5cbmNvbnN0IHByaW9yaXR5V2VpZ2h0czogeyBba2V5IGluIFByaW9yaXR5XTogbnVtYmVyIH0gPSB7XG4gIGhpZ2g6IDMsXG4gIG5vcm1hbDogMixcbiAgbG93OiAxXG59O1xuIl19

@@ -6,2 +6,93 @@ # Change Log

# [1.0.0-gamma.1](https://github.com/aws/aws-sdk-js-v3/compare/@aws-sdk/middleware-stack@0.1.0-preview.3...@aws-sdk/middleware-stack@1.0.0-gamma.1) (2020-05-21)
### Features
* bump up to gamma version ([#1192](https://github.com/aws/aws-sdk-js-v3/issues/1192)) ([a609075](https://github.com/aws/aws-sdk-js-v3/commit/a6090754f2a6c21e5b70bf0c8782cc0fbe59ee12))
# 1.0.0-beta.4 (2020-04-25)
# 1.0.0-beta.2 (2020-03-28)
# 1.0.0-beta.1 (2020-03-25)
### Features
* bump packages to beta ([#1050](https://github.com/aws/aws-sdk-js-v3/issues/1050)) ([40501d4](https://github.com/aws/aws-sdk-js-v3/commit/40501d4394d04bc1bc91c10136fa48b1d3a67d8f))
# 1.0.0-alpha.28 (2020-03-20)
# 1.0.0-alpha.24 (2020-02-19)
# 1.0.0-alpha.13 (2020-01-24)
# 1.0.0-alpha.12 (2020-01-22)
# 0.9.0 (2020-01-09)
### Bug Fixes
* fix bugs when recursively appending middleware ([#476](https://github.com/aws/aws-sdk-js-v3/issues/476)) ([5afc0d6](https://github.com/aws/aws-sdk-js-v3/commit/5afc0d6368ce5cc867425325b3eb77db6090f077))
### Features
* apply protocol and middleware update ([0de0a22](https://github.com/aws/aws-sdk-js-v3/commit/0de0a22c2a97a0dd3d27eee67e5e31fb32402a11))
* remove absolute priority numbers from middleware stack ([#434](https://github.com/aws/aws-sdk-js-v3/issues/434)) ([2ad5796](https://github.com/aws/aws-sdk-js-v3/commit/2ad579698f5679a0cb120daad38d539e2944abed))
* standardize plugins ([#422](https://github.com/aws/aws-sdk-js-v3/issues/422)) ([09112e5](https://github.com/aws/aws-sdk-js-v3/commit/09112e5a61dcb4a4c5ef5e544c1964545d30e046))
# 0.7.0 (2019-11-19)
# 0.6.0 (2019-10-30)
# 0.3.0 (2019-09-09)
### Features
* commit all clients ([#324](https://github.com/aws/aws-sdk-js-v3/issues/324)) ([cb268ed](https://github.com/aws/aws-sdk-js-v3/commit/cb268ed45fd5580ef9633da78f13aaa6aa472805))
# 0.2.0 (2019-07-12)
### Features
* add npm badges for individual packages ([#251](https://github.com/aws/aws-sdk-js-v3/issues/251)) ([8adc10c](https://github.com/aws/aws-sdk-js-v3/commit/8adc10cb6b0ebc32004b797556bfc171c96bbf16))
* update jest v20 to v24 ([#243](https://github.com/aws/aws-sdk-js-v3/issues/243)) ([1e156ab](https://github.com/aws/aws-sdk-js-v3/commit/1e156ab4ac5343058eaf7d448a428d8c4b72c844))
# 0.1.0 (2019-04-19)
# [1.0.0-beta.4](https://github.com/aws/aws-sdk-js-v3/compare/@aws-sdk/middleware-stack@0.1.0-preview.3...@aws-sdk/middleware-stack@1.0.0-beta.4) (2020-04-27)

@@ -8,0 +99,0 @@

{
"name": "@aws-sdk/middleware-stack",
"version": "1.0.0-beta.4",
"version": "1.0.0-gamma.1",
"description": "Provides a means for composing multiple middleware functions into a single handler",

@@ -19,3 +19,3 @@ "scripts": {

"dependencies": {
"@aws-sdk/types": "1.0.0-beta.4",
"@aws-sdk/types": "1.0.0-gamma.1",
"tslib": "^1.8.0"

@@ -22,0 +22,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