Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Comments

Close side panel

- fixes a bug where url options would be inserted twice for collection POST requests#281

Merged
baywet merged 2 commits intodevmicrosoftgraph/MSGraph-SDK-Code-Generator:devfrom
bugfix/collection-post-duplicate-optionsmicrosoftgraph/MSGraph-SDK-Code-Generator:bugfix/collection-post-duplicate-optionsCopy head branch name to clipboard
Sep 3, 2020
Merged

- fixes a bug where url options would be inserted twice for collection POST requests#281
baywet merged 2 commits intodevmicrosoftgraph/MSGraph-SDK-Code-Generator:devfrom
bugfix/collection-post-duplicate-optionsmicrosoftgraph/MSGraph-SDK-Code-Generator:bugfix/collection-post-duplicate-optionsCopy head branch name to clipboard

Conversation

@baywet
Copy link
Member

@baywet baywet commented Sep 3, 2020

Summary

Because getRequestUrl already inserts the options (functions and query), providing the options again in build request was inserting those twice, causing the request to fail.

Generated code differences

microsoftgraph/msgraph-sdk-java#445

Command line arguments to run these changes

Provide the command line arguments here so that reviewers can quickly repro the results of changes.

Links to issues or work items this PR addresses

@zengin
Copy link
Contributor

zengin commented Sep 3, 2020

I understand the removal of getOptions(), but I am trying to understand addition of getHeaders().

My assumption looking at the code change is that getOptions() was adding options as well as headers, and as you replace it with getHeaders() we are only keeping headers. Is that correct?

@baywet
Copy link
Member Author

baywet commented Sep 3, 2020

yes we're only keeping the request headers. That's because getrequesturl already adds the functions and query parameters in the URL but not the headers.

Copy link
Contributor

@zengin zengin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the clarification.

@baywet baywet merged commit 68522f1 into dev Sep 3, 2020
@baywet baywet deleted the bugfix/collection-post-duplicate-options branch September 3, 2020 20:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.