fix: makeShared for QByteArray

Signed-off-by: Sefa Eyeoglu <contact@scrumplex.net>
This commit is contained in:
Sefa Eyeoglu 2023-08-06 21:51:03 +02:00
parent 6d5a2ceefe
commit a83e5be8f2
No known key found for this signature in database
GPG Key ID: E13DFD4B47127951
2 changed files with 2 additions and 2 deletions

View File

@ -1078,7 +1078,7 @@ void MainWindow::processURLs(QList<QUrl> urls)
extra_info.insert("pack_id", addonId);
extra_info.insert("pack_version_id", fileId);
auto array = new QByteArray();
auto array = std::make_shared<QByteArray>();
auto api = FlameAPI();
auto job = api.getFile(addonId, fileId, array);

View File

@ -134,7 +134,7 @@ void ImportPage::updateState()
QUrlQuery query(url);
auto addonId = query.allQueryItemValues("addonId")[0];
auto fileId = query.allQueryItemValues("fileId")[0];
auto array = new QByteArray();
auto array = std::make_shared<QByteArray>();
auto api = FlameAPI();
auto job = api.getFile(addonId, fileId, array);