Skip to content

Commit

Permalink
fix: undeclared variable (#109)
Browse files Browse the repository at this point in the history
  • Loading branch information
mohnishparmar authored Dec 9, 2024
1 parent 64b4d66 commit 1e6a295
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions riva/client/nmt.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ def streaming_s2t_request_generator(
yield riva_nmt.StreamingTranslateSpeechToTextRequest(audio_content=chunk)

def add_dnt_phrases_dict(req, dnt_phrases_dict):
dnt_phrases = None
if dnt_phrases_dict is not None:
dnt_phrases = [f"{key}##{value}" for key, value in dnt_phrases_dict.items()]
if dnt_phrases:
Expand Down
1 change: 1 addition & 0 deletions riva/client/tts.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import wave

def add_custom_dictionary_to_config(req, custom_dictionary):
result_list = None
if custom_dictionary is not None:
result_list = [f"{key} {value}" for key, value in custom_dictionary.items()]
if result_list:
Expand Down

0 comments on commit 1e6a295

Please sign in to comment.