Skip to content

Commit

Permalink
chore: define headers while declaring (#1134)
Browse files Browse the repository at this point in the history
  • Loading branch information
trivikr committed May 11, 2020
1 parent 2665c30 commit 1bd0678
Show file tree
Hide file tree
Showing 225 changed files with 26,643 additions and 19,976 deletions.
90 changes: 54 additions & 36 deletions clients/client-accessanalyzer/protocols/Aws_restJson1_1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,9 @@ export const serializeAws_restJson1_1CreateAnalyzerCommand = async (
input: CreateAnalyzerCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "application/json";
const headers: any = {
"Content-Type": "application/json"
};
let resolvedPath = "/analyzer";
let body: any;
const bodyParams: any = {};
Expand Down Expand Up @@ -152,8 +153,9 @@ export const serializeAws_restJson1_1CreateArchiveRuleCommand = async (
input: CreateArchiveRuleCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "application/json";
const headers: any = {
"Content-Type": "application/json"
};
let resolvedPath = "/analyzer/{analyzerName}/archive-rule";
if (input.analyzerName !== undefined) {
const labelValue: string = input.analyzerName;
Expand Down Expand Up @@ -203,8 +205,9 @@ export const serializeAws_restJson1_1DeleteAnalyzerCommand = async (
input: DeleteAnalyzerCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "";
const headers: any = {
"Content-Type": ""
};
let resolvedPath = "/analyzer/{analyzerName}";
if (input.analyzerName !== undefined) {
const labelValue: string = input.analyzerName;
Expand Down Expand Up @@ -241,8 +244,9 @@ export const serializeAws_restJson1_1DeleteArchiveRuleCommand = async (
input: DeleteArchiveRuleCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "";
const headers: any = {
"Content-Type": ""
};
let resolvedPath = "/analyzer/{analyzerName}/archive-rule/{ruleName}";
if (input.analyzerName !== undefined) {
const labelValue: string = input.analyzerName;
Expand Down Expand Up @@ -291,8 +295,9 @@ export const serializeAws_restJson1_1GetAnalyzedResourceCommand = async (
input: GetAnalyzedResourceCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "";
const headers: any = {
"Content-Type": ""
};
let resolvedPath = "/analyzed-resource";
const query: any = {
...(input.analyzerArn !== undefined && { analyzerArn: input.analyzerArn }),
Expand All @@ -316,8 +321,9 @@ export const serializeAws_restJson1_1GetAnalyzerCommand = async (
input: GetAnalyzerCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "";
const headers: any = {
"Content-Type": ""
};
let resolvedPath = "/analyzer/{analyzerName}";
if (input.analyzerName !== undefined) {
const labelValue: string = input.analyzerName;
Expand Down Expand Up @@ -350,8 +356,9 @@ export const serializeAws_restJson1_1GetArchiveRuleCommand = async (
input: GetArchiveRuleCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "";
const headers: any = {
"Content-Type": ""
};
let resolvedPath = "/analyzer/{analyzerName}/archive-rule/{ruleName}";
if (input.analyzerName !== undefined) {
const labelValue: string = input.analyzerName;
Expand Down Expand Up @@ -396,8 +403,9 @@ export const serializeAws_restJson1_1GetFindingCommand = async (
input: GetFindingCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "";
const headers: any = {
"Content-Type": ""
};
let resolvedPath = "/finding/{id}";
if (input.id !== undefined) {
const labelValue: string = input.id;
Expand Down Expand Up @@ -432,8 +440,9 @@ export const serializeAws_restJson1_1ListAnalyzedResourcesCommand = async (
input: ListAnalyzedResourcesCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "application/json";
const headers: any = {
"Content-Type": "application/json"
};
let resolvedPath = "/analyzed-resource";
let body: any;
const bodyParams: any = {};
Expand Down Expand Up @@ -466,8 +475,9 @@ export const serializeAws_restJson1_1ListAnalyzersCommand = async (
input: ListAnalyzersCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "";
const headers: any = {
"Content-Type": ""
};
let resolvedPath = "/analyzer";
const query: any = {
...(input.maxResults !== undefined && {
Expand All @@ -494,8 +504,9 @@ export const serializeAws_restJson1_1ListArchiveRulesCommand = async (
input: ListArchiveRulesCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "";
const headers: any = {
"Content-Type": ""
};
let resolvedPath = "/analyzer/{analyzerName}/archive-rule";
if (input.analyzerName !== undefined) {
const labelValue: string = input.analyzerName;
Expand Down Expand Up @@ -535,8 +546,9 @@ export const serializeAws_restJson1_1ListFindingsCommand = async (
input: ListFindingsCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "application/json";
const headers: any = {
"Content-Type": "application/json"
};
let resolvedPath = "/finding";
let body: any;
const bodyParams: any = {};
Expand Down Expand Up @@ -578,8 +590,9 @@ export const serializeAws_restJson1_1ListTagsForResourceCommand = async (
input: ListTagsForResourceCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "";
const headers: any = {
"Content-Type": ""
};
let resolvedPath = "/tags/{resourceArn}";
if (input.resourceArn !== undefined) {
const labelValue: string = input.resourceArn;
Expand Down Expand Up @@ -612,8 +625,9 @@ export const serializeAws_restJson1_1StartResourceScanCommand = async (
input: StartResourceScanCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "application/json";
const headers: any = {
"Content-Type": "application/json"
};
let resolvedPath = "/resource/scan";
let body: any;
const bodyParams: any = {};
Expand All @@ -640,8 +654,9 @@ export const serializeAws_restJson1_1TagResourceCommand = async (
input: TagResourceCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "application/json";
const headers: any = {
"Content-Type": "application/json"
};
let resolvedPath = "/tags/{resourceArn}";
if (input.resourceArn !== undefined) {
const labelValue: string = input.resourceArn;
Expand Down Expand Up @@ -679,8 +694,9 @@ export const serializeAws_restJson1_1UntagResourceCommand = async (
input: UntagResourceCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "";
const headers: any = {
"Content-Type": ""
};
let resolvedPath = "/tags/{resourceArn}";
if (input.resourceArn !== undefined) {
const labelValue: string = input.resourceArn;
Expand Down Expand Up @@ -719,8 +735,9 @@ export const serializeAws_restJson1_1UpdateArchiveRuleCommand = async (
input: UpdateArchiveRuleCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "application/json";
const headers: any = {
"Content-Type": "application/json"
};
let resolvedPath = "/analyzer/{analyzerName}/archive-rule/{ruleName}";
if (input.analyzerName !== undefined) {
const labelValue: string = input.analyzerName;
Expand Down Expand Up @@ -779,8 +796,9 @@ export const serializeAws_restJson1_1UpdateFindingsCommand = async (
input: UpdateFindingsCommandInput,
context: __SerdeContext
): Promise<__HttpRequest> => {
const headers: any = {};
headers["Content-Type"] = "application/json";
const headers: any = {
"Content-Type": "application/json"
};
let resolvedPath = "/finding";
let body: any;
const bodyParams: any = {};
Expand Down

0 comments on commit 1bd0678

Please sign in to comment.