summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/imitatepass.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/imitatepass.cpp b/src/imitatepass.cpp
index 82be1d91..2140505b 100644
--- a/src/imitatepass.cpp
+++ b/src/imitatepass.cpp
@@ -366,9 +366,9 @@ void ImitatePass::Move(const QString src, const QString dest,
destFile = dest;
}
- if (!destFile.endsWith(".gpg"))
- destFile.append(".gpg");
-
+ if (destFile.endsWith(".gpg", Qt::CaseInsensitive))
+ destFile.chop(4); // make sure suffix is lowercase
+ destFile.append(".gpg");
} else if (srcFileInfo.isDir()) {
if (destFileInfo.isDir()) {
destFile = QDir(dest).filePath(srcFileBaseName);