diff options
| author | yum <yum.food.vr@gmail.com> | 2024-07-12 16:08:22 -0700 |
|---|---|---|
| committer | yum <yum.food.vr@gmail.com> | 2024-07-12 16:08:22 -0700 |
| commit | d7307f8b4d7a8871f08c5999e551b9f58d256c1c (patch) | |
| tree | 395304995a567f6b65b1c95d8e0e943639b941ed /Scripts | |
| parent | 861df4f98db7c8a87fd11f9081b0c8c6d6d40f29 (diff) | |
Edge case: initial preview should not have a space added in front of it
God this code is a fucking nightmare
Diffstat (limited to 'Scripts')
| -rw-r--r-- | Scripts/transcribe_v2.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Scripts/transcribe_v2.py b/Scripts/transcribe_v2.py index 94b8257..ba05dd0 100644 --- a/Scripts/transcribe_v2.py +++ b/Scripts/transcribe_v2.py @@ -844,8 +844,9 @@ def transcriptionThread(ctrl: ThreadControl): if not ctrl.transcript.endswith(' ') and not \ commit.delta.startswith(' '): commit.delta = ' ' + commit.delta - if not commit.delta.endswith(' ') and not \ - commit.preview.startswith(' '): + if len(commit.delta) > 0 and \ + (not commit.delta.endswith(' ')) and \ + (not commit.preview.startswith(' ')): commit.preview = ' ' + commit.preview ctrl.transcript += commit.delta |
