mirror of
https://github.com/nomic-ai/gpt4all.git
synced 2025-09-07 19:40:21 +00:00
Fixed tons of warnings and clazy findings (#811)
This commit is contained in:
@@ -74,7 +74,7 @@ QList<ModelInfo> Download::modelList() const
|
||||
ModelInfo bestLlamaInfo;
|
||||
ModelInfo bestMPTInfo;
|
||||
QList<ModelInfo> filtered;
|
||||
for (ModelInfo v : values) {
|
||||
for (const ModelInfo &v : values) {
|
||||
if (v.isDefault)
|
||||
defaultInfo = v;
|
||||
if (v.bestGPTJ)
|
||||
@@ -310,7 +310,7 @@ void Download::removeModel(const QString &modelFile)
|
||||
void Download::handleSslErrors(QNetworkReply *reply, const QList<QSslError> &errors)
|
||||
{
|
||||
QUrl url = reply->request().url();
|
||||
for (auto e : errors)
|
||||
for (const auto &e : errors)
|
||||
qWarning() << "ERROR: Received ssl error:" << e.errorString() << "for" << url;
|
||||
}
|
||||
|
||||
@@ -658,7 +658,6 @@ void Download::handleReadyRead()
|
||||
if (!modelReply)
|
||||
return;
|
||||
|
||||
QString modelFilename = modelReply->url().fileName();
|
||||
QFile *tempFile = m_activeDownloads.value(modelReply);
|
||||
QByteArray buffer;
|
||||
while (!modelReply->atEnd()) {
|
||||
|
Reference in New Issue
Block a user