@aws-sdk/middleware-expect-continue 3.183.0 → 3.186.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,14 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.186.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.185.0...v3.186.0) (2022-10-06)
7
+
8
+ **Note:** Version bump only for package @aws-sdk/middleware-expect-continue
9
+
10
+
11
+
12
+
13
+
6
14
  # [3.183.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.182.0...v3.183.0) (2022-10-03)
7
15
 
8
16
  **Note:** Version bump only for package @aws-sdk/middleware-expect-continue
package/dist-es/index.js CHANGED
@@ -1,27 +1,28 @@
1
+ import { __assign, __awaiter, __generator } from "tslib";
1
2
  import { HttpRequest } from "@aws-sdk/protocol-http";
2
3
  export function addExpectContinueMiddleware(options) {
3
- return (next) => async (args) => {
4
- const { request } = args;
5
- if (HttpRequest.isInstance(request) && request.body && options.runtime === "node") {
6
- request.headers = {
7
- ...request.headers,
8
- Expect: "100-continue",
9
- };
10
- }
11
- return next({
12
- ...args,
13
- request,
14
- });
4
+ var _this = this;
5
+ return function (next) {
6
+ return function (args) { return __awaiter(_this, void 0, void 0, function () {
7
+ var request;
8
+ return __generator(this, function (_a) {
9
+ request = args.request;
10
+ if (HttpRequest.isInstance(request) && request.body && options.runtime === "node") {
11
+ request.headers = __assign(__assign({}, request.headers), { Expect: "100-continue" });
12
+ }
13
+ return [2, next(__assign(__assign({}, args), { request: request }))];
14
+ });
15
+ }); };
15
16
  };
16
17
  }
17
- export const addExpectContinueMiddlewareOptions = {
18
+ export var addExpectContinueMiddlewareOptions = {
18
19
  step: "build",
19
20
  tags: ["SET_EXPECT_HEADER", "EXPECT_HEADER"],
20
21
  name: "addExpectContinueMiddleware",
21
22
  override: true,
22
23
  };
23
- export const getAddExpectContinuePlugin = (options) => ({
24
- applyToStack: (clientStack) => {
24
+ export var getAddExpectContinuePlugin = function (options) { return ({
25
+ applyToStack: function (clientStack) {
25
26
  clientStack.add(addExpectContinueMiddleware(options), addExpectContinueMiddlewareOptions);
26
27
  },
27
- });
28
+ }); };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aws-sdk/middleware-expect-continue",
3
- "version": "3.183.0",
3
+ "version": "3.186.0",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
6
6
  "build:cjs": "tsc -p tsconfig.cjs.json",
@@ -20,8 +20,8 @@
20
20
  },
21
21
  "license": "Apache-2.0",
22
22
  "dependencies": {
23
- "@aws-sdk/protocol-http": "3.183.0",
24
- "@aws-sdk/types": "3.183.0",
23
+ "@aws-sdk/protocol-http": "3.186.0",
24
+ "@aws-sdk/types": "3.186.0",
25
25
  "tslib": "^2.3.1"
26
26
  },
27
27
  "engines": {