Skip to content

Commit

Permalink
fix: fix getTransactionId method for the RecognizeStream class
Browse files Browse the repository at this point in the history
  • Loading branch information
dpopp07 committed Jan 18, 2019
1 parent f007a19 commit e5bbe2c
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lib/recognize-stream.ts
Expand Up @@ -36,7 +36,9 @@ const OPENING_MESSAGE_PARAMS_ALLOWED = [
'word_alternatives_threshold',
'profanity_filter',
'smart_formatting',
'speaker_labels'
'speaker_labels',
'grammar_name',
'redaction'
];

const QUERY_PARAMS_ALLOWED = [
Expand All @@ -45,9 +47,7 @@ const QUERY_PARAMS_ALLOWED = [
'watson-token',
'language_customization_id',
'customization_id',
'acoustic_customization_id',
'grammar_name',
'redaction'
'acoustic_customization_id'
];

interface RecognizeStream extends Duplex {
Expand Down Expand Up @@ -506,7 +506,7 @@ class RecognizeStream extends Duplex {
this.socket._client.response.headers['x-global-transaction-id']
);
} else {
this.on('connect', () =>
this.on('open', () =>
resolve(
this.socket._client.response.headers['x-global-transaction-id']
)
Expand Down

0 comments on commit e5bbe2c

Please sign in to comment.