matlab-deep-learning/llms-with-matlab

Incorrect error message when removing message from empty messageHistory

Closed this issue · 0 comments

When I try to remove a message from an empty messageHistory, the error message is technically incorrect:

>> messages = messageHistory;
>> removeMessage(messages,1)
Error using messageHistory/removeMessage (line 217)
Index exceeds the number of array elements. Index
must be less than or equal to 0.