-
Notifications
You must be signed in to change notification settings - Fork 670
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: send correct user-agent header for websocket methods #930
Conversation
Codecov Report
@@ Coverage Diff @@
## master #930 +/- ##
==========================================
+ Coverage 54.34% 54.39% +0.05%
==========================================
Files 18 18
Lines 4501 4502 +1
Branches 905 905
==========================================
+ Hits 2446 2449 +3
+ Misses 2053 2051 -2
Partials 2 2
Continue to review full report at Codecov.
|
@@ -87,11 +86,13 @@ class TextToSpeechV1 extends GeneratedTextToSpeechV1 { | |||
params.token_manager = this.tokenManager; | |||
} | |||
|
|||
// include analytics headers | |||
const sdkHeaders = getSdkHeaders('text_to_speech', 'v1', 'synthesizeUsingWebSocket'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will this break the browser users?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm I'm not sure. We were still sending the user-agent
header before but not the x-ibm-cloud-analytics
header so it depends on if that will cause CORS issues.
That said, these two operations are the ones we have a completely separate browser package for so I don't know if it's a big deal 🤷♂
(cherry picked from commit f24cac2)
## [4.3.3](v4.3.2...v4.3.3) (2019-08-08) ### Bug Fixes * send correct user-agent header for websocket methods ([#930](#930)) ([f24cac2](f24cac2))
🎉 This PR is included in version 4.3.3 🎉 The release is available on: Your semantic-release bot 📦🚀 |
I recently noticed that the analytics headers for the WebSocket methods do not follow the new format. Making this quick change to correct them