refactor: Inject settings into LLMClientInterface (#114)

This reduces reliance on global state and makes it more possible to test
the code.
This commit is contained in:
Povilas Kanapickas
2025-03-08 16:08:15 +02:00
committed by GitHub
parent 3a494d5254
commit 6c323642e4
5 changed files with 40 additions and 31 deletions

View File

@ -45,7 +45,8 @@ using namespace Core;
namespace QodeAssist {
QodeAssistClient::QodeAssistClient()
: LanguageClient::Client(new LLMClientInterface())
: LanguageClient::Client(
new LLMClientInterface(Settings::generalSettings(), Settings::codeCompletionSettings()))
, m_recentCharCount(0)
{
setName("Qode Assist");