1
0
mirror of https://github.com/QRouland/UTPass.git synced 2025-06-24 22:42:28 +00:00

Use tmp dir during clone to keep orignal passstore in case of error

This commit is contained in:
2025-01-10 14:41:04 +01:00
parent 80a5055b78
commit 3aa99791b8
8 changed files with 45 additions and 18 deletions

View File

@ -7,12 +7,10 @@
#include "utils.h"
Utils::Utils() {};
bool Utils::unzip(QUrl zip_url, QString dir_out_path)
{
auto tmp_dir_path = QStandardPaths::writableLocation(
QStandardPaths::TempLocation).append("/unzip");
QStandardPaths::CacheLocation).append("/unzip");
QDir tmp_dir(tmp_dir_path);
tmp_dir.removeRecursively();

View File

@ -10,7 +10,7 @@ class Utils : public QObject
Q_OBJECT
public:
Utils();
Utils() = default;
~Utils() override = default;
Q_INVOKABLE bool unzip(QUrl zip_url, QString dir_out);