Skip to content

Commit 68777d1

Browse files
author
James Walker
committed
modify get channel to properly take moved channels into account
1 parent cef0468 commit 68777d1

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

speechmatics/cli.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -590,10 +590,7 @@ def transcript_handler(message):
590590
transcripts.text += plaintext
591591

592592
def get_channel(message):
593-
return next(
594-
(result["channel"] for result in message["results"] if "channel" in result),
595-
None,
596-
)
593+
return message.get("channel", None)
597594

598595
def audio_event_handler(message):
599596
if print_json:

0 commit comments

Comments
 (0)