Skip to content

Commit 4b2b108

Browse files
committed
Fix regression
1 parent c3ab628 commit 4b2b108

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Public/Chat/Request-ChatCompletion.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -699,7 +699,7 @@ function Request-ChatCompletion {
699699
#endregion
700700

701701
#region For history, add AI response to messages list.
702-
if ($Response.choices.message.Count -ge 1) {
702+
if (@($Response.choices.message).Count -ge 1) {
703703
$msg = @($Response.choices.message)[0]
704704
$rcm = [ordered]@{
705705
role = $msg.role

0 commit comments

Comments
 (0)