diff --git a/cpp/web_server.cpp b/cpp/web_server.cpp index c2727e8..26cc730 100644 --- a/cpp/web_server.cpp +++ b/cpp/web_server.cpp @@ -199,7 +199,7 @@ bool WebServer::start_server(quint16 port) { } } - expire_tokens_thread_ = std::jthread(run_task_every, 60, [this, lubuntuci] { + expire_tokens_thread_ = std::jthread(run_task_every, 60, [this, &lubuntuci] mutable { QSqlQuery expired_tokens(get_thread_connection()); QString current_time = QDateTime::currentDateTime().toString(Qt::ISODate); @@ -216,7 +216,7 @@ bool WebServer::start_server(quint16 port) { } }); - process_sources_thread_ = std::jthread(run_task_every, 10, [this, all_repos, proposed, lubuntuci, job_statuses] { + process_sources_thread_ = std::jthread(run_task_every, 10, [this, &all_repos, &proposed, &lubuntuci, &job_statuses] mutable { for (auto pkgconf : all_repos) { if (!pkgconf->can_check_source_upload()) { continue; } @@ -241,7 +241,7 @@ bool WebServer::start_server(quint16 port) { } }); - process_binaries_thread_ = std::jthread(run_task_every, 10, [this, all_repos, proposed, lubuntuci, job_statuses] { + process_binaries_thread_ = std::jthread(run_task_every, 10, [this, &all_repos, &proposed, &lubuntuci, &job_statuses] mutable { for (auto pkgconf : all_repos) { if (!pkgconf->can_check_builds()) { continue; }