mirror of
https://github.com/QRouland/UTPass.git
synced 2026-01-10 19:36:57 +00:00
Ensure that key and zip are deleted after import
This commit is contained in:
@@ -29,7 +29,7 @@ void Utils::unzipResult(bool err)
|
||||
qDebug() << "Unzip Result";
|
||||
if (err) {
|
||||
qInfo() << "Unzip Failed";
|
||||
emit unzipFailed("failed to unzip archive");
|
||||
emit unzipFailed();
|
||||
|
||||
} else {
|
||||
qInfo() << "Unzip Succeed";
|
||||
@@ -45,3 +45,14 @@ QString Utils::manifestPath()
|
||||
qInfo() << "Manifest path : " << path;
|
||||
return path;
|
||||
}
|
||||
|
||||
bool Utils::rmFile(QUrl file_url)
|
||||
{
|
||||
return QFile::remove(file_url.toLocalFile());
|
||||
}
|
||||
|
||||
bool Utils::rmDir(QUrl dir_url)
|
||||
{
|
||||
QDir dir(dir_url.toLocalFile());
|
||||
return dir.removeRecursively();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user