MCPcopy Create free account
hub / github.com/Palm1r/QodeAssist / saveHistory

Method saveHistory

ChatView/ChatRootView.cpp:536–553  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

534}
535
536void ChatRootView::saveHistory(const QString &filePath)
537{
538 if (filePath != m_recentFilePath) {
539 if (auto registry = sessionFileRegistry(); registry && registry->isLocked(filePath)) {
540 m_lastErrorMessage
541 = tr("This chat file is already in use by another QodeAssist chat session.");
542 emit lastErrorMessageChanged();
543 return;
544 }
545 }
546
547 auto result = m_historyStore->save(filePath);
548 if (!result.success) {
549 LOG_MESSAGE(QString("Failed to save chat history: %1").arg(result.errorMessage));
550 } else {
551 setRecentFilePath(filePath);
552 }
553}
554
555void ChatRootView::loadHistory(const QString &filePath)
556{

Callers

nothing calls this directly

Calls 2

isLockedMethod · 0.80
saveMethod · 0.45

Tested by

no test coverage detected