From 6ed3d01f174c64dcc9d4f669e55b56916472ed5b Mon Sep 17 00:00:00 2001 From: Adam Treat Date: Thu, 7 Mar 2024 14:37:08 -0500 Subject: [PATCH] Fix issue #2087 where cloned models were lost and listed in download dialog erroneously. Signed-off-by: Adam Treat --- gpt4all-chat/modellist.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gpt4all-chat/modellist.cpp b/gpt4all-chat/modellist.cpp index f5676562..da950bfb 100644 --- a/gpt4all-chat/modellist.cpp +++ b/gpt4all-chat/modellist.cpp @@ -393,7 +393,8 @@ bool DownloadableModels::filterAcceptsRow(int sourceRow, bool isDownloadable = !sourceModel()->data(index, ModelList::DescriptionRole).toString().isEmpty(); bool isInstalled = !sourceModel()->data(index, ModelList::InstalledRole).toString().isEmpty(); bool isIncomplete = !sourceModel()->data(index, ModelList::IncompleteRole).toString().isEmpty(); - return withinLimit && (isDownloadable || isInstalled || isIncomplete); + bool isClone = sourceModel()->data(index, ModelList::IsCloneRole).toBool(); + return withinLimit && !isClone && (isDownloadable || isInstalled || isIncomplete); } int DownloadableModels::count() const