Skip to content

Commit

Permalink
fix(ui): set content-type for certain UI requests (argoproj#16923)
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Crenshaw <[email protected]>
  • Loading branch information
crenshaw-dev committed Jan 19, 2024
1 parent 8a0bf41 commit cef8b12
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ui/src/app/shared/services/applications-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,7 @@ export class ApplicationsService {
kind: resource.kind,
group: resource.group
})
.set("Content-Type", "application/json")
.send(JSON.stringify(action))
.then(res => (res.body.actions as models.ResourceAction[]) || []);
}
Expand All @@ -345,6 +346,7 @@ export class ApplicationsService {
group: resource.group || '', // The group query param must be present even if empty.
patchType
})
.set("Content-Type", "application/json")
.send(JSON.stringify(patch))
.then(res => res.body as {manifest: string})
.then(res => JSON.parse(res.manifest) as models.State);
Expand All @@ -364,6 +366,7 @@ export class ApplicationsService {
force,
orphan
})
.set('Content-Type', 'application/json')
.send()
.then(() => true);
}
Expand Down

0 comments on commit cef8b12

Please sign in to comment.