diff options
author | Trial97 <alexandru.tripon97@gmail.com> | 2023-06-23 20:01:17 +0300 |
---|---|---|
committer | Trial97 <alexandru.tripon97@gmail.com> | 2023-06-23 20:01:17 +0300 |
commit | 69c709b05a90f342cc9d1f9337457bb5519a87a9 (patch) | |
tree | 4ff1cbe8123b627bfb171c119b3adc4e2ddaf89b /launcher/modplatform/modrinth/ModrinthPackExportTask.cpp | |
parent | 3e3be9ae6f902cc292ee26e4d330b078ddbb2a46 (diff) | |
parent | 046d510134a0061c0a1fa89fda80355c9e2f11ff (diff) | |
download | PrismLauncher-69c709b05a90f342cc9d1f9337457bb5519a87a9.tar.gz PrismLauncher-69c709b05a90f342cc9d1f9337457bb5519a87a9.tar.bz2 PrismLauncher-69c709b05a90f342cc9d1f9337457bb5519a87a9.zip |
Merge branch 'develop' of https://github.com/PrismLauncher/PrismLauncher into develop
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
Diffstat (limited to 'launcher/modplatform/modrinth/ModrinthPackExportTask.cpp')
-rw-r--r-- | launcher/modplatform/modrinth/ModrinthPackExportTask.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/launcher/modplatform/modrinth/ModrinthPackExportTask.cpp b/launcher/modplatform/modrinth/ModrinthPackExportTask.cpp index bff9bf42..c607bb89 100644 --- a/launcher/modplatform/modrinth/ModrinthPackExportTask.cpp +++ b/launcher/modplatform/modrinth/ModrinthPackExportTask.cpp @@ -157,7 +157,7 @@ void ModrinthPackExportTask::makeApiRequest() if (pendingHashes.isEmpty()) buildZip(); else { - QByteArray* response = new QByteArray; + auto response = std::make_shared<QByteArray>(); task = api.currentVersions(pendingHashes.values(), "sha512", response); connect(task.get(), &NetJob::succeeded, [this, response]() { parseApiResponse(response); }); connect(task.get(), &NetJob::failed, this, &ModrinthPackExportTask::emitFailed); @@ -165,7 +165,7 @@ void ModrinthPackExportTask::makeApiRequest() } } -void ModrinthPackExportTask::parseApiResponse(const QByteArray* response) +void ModrinthPackExportTask::parseApiResponse(const std::shared_ptr<QByteArray> response) { task = nullptr; |