Skip to content

Bug fix: Use configured prototcol for API requests#300

Merged
dubee merged 1 commit intoapache:masterfrom
dgrove-oss:avoid-double-https-in-api-create
May 30, 2018
Merged

Bug fix: Use configured prototcol for API requests#300
dubee merged 1 commit intoapache:masterfrom
dgrove-oss:avoid-double-https-in-api-create

Conversation

@dgrove-oss
Copy link
Copy Markdown
Member

Add check to see if Client.Config.Host already specifies the protocol
to use before prepending https:// in URL construction.
Fixes a bug where if .wskprops specifies a APIHOST with a protocol,
wsk api create generates an invalid backend URL (https://https://APIHOST/...).

Fixes #125.

@dgrove-oss dgrove-oss requested a review from dubee May 17, 2018 13:56
@dgrove-oss dgrove-oss force-pushed the avoid-double-https-in-api-create branch from c321dda to db17116 Compare May 17, 2018 13:59
Copy link
Copy Markdown
Member

@dubee dubee left a comment

Choose a reason for hiding this comment

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

@dgrove-oss, is it possible to write a test for this?

@dubee
Copy link
Copy Markdown
Member

dubee commented May 18, 2018

@mdeuser, FYI.

@dgrove-oss dgrove-oss force-pushed the avoid-double-https-in-api-create branch from db17116 to 5e4b7b5 Compare May 23, 2018 14:28
Add check to see if Client.Config.Host already specifies the protocol
to use before prepending https:// in URL construction.
Fixes a bug where if .wskprops specifies a APIHOST with a protocol,
`wsk api create` generates an invalid backend URL (https://https://APIHOST/...).

Also add unit test to check for this error condition.

Fixes apache#125.
@dgrove-oss dgrove-oss force-pushed the avoid-double-https-in-api-create branch from 7480066 to 155de29 Compare May 29, 2018 18:45
@dgrove-oss
Copy link
Copy Markdown
Member Author

@dubee -- I added a test. I think this is ready for final review & merge now.

@dubee dubee merged commit 0c34a07 into apache:master May 30, 2018
@dgrove-oss dgrove-oss deleted the avoid-double-https-in-api-create branch May 31, 2018 18:48
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.

3 participants