Skip to content

Commit

Permalink
Fix: Code snippet generation (#1559)
Browse files Browse the repository at this point in the history
  • Loading branch information
thewahome authored Mar 16, 2022
1 parent 6934106 commit 80a4b09
Show file tree
Hide file tree
Showing 3 changed files with 62 additions and 13 deletions.
68 changes: 58 additions & 10 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "graph-explorer-v2",
"version": "4.18.0",
"version": "4.18.1",
"private": true,
"dependencies": {
"@augloop/types-core": "file:packages/types-core-2.16.189.tgz",
Expand Down
5 changes: 3 additions & 2 deletions src/app/services/actions/snippet-action-creator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,9 @@ export function getSnippet(language: string): Function {
? JSON.stringify(sampleQuery.sampleBody)
: '';

const body = `${sampleQuery.selectedVerb} /${queryVersion}/${requestUrl + search}
HTTP/1.1\r\nHost: graph.microsoft.com\r\nContent-Type: application/json\r\n\r\n${requestBody}`;
// eslint-disable-next-line max-len
const body = `${sampleQuery.selectedVerb} /${queryVersion}/${requestUrl + search} HTTP/1.1\r\nHost: graph.microsoft.com\r\nContent-Type: application/json\r\n\r\n${requestBody}`;

const options: IRequestOptions = { method, headers, body };
const obj: any = {};

Expand Down

0 comments on commit 80a4b09

Please sign in to comment.