Skip to content

TagSpaces is an offline, open source, document manager with tagging support

fixing issue with not working saving of *.html urls as mhtml

uggrock6d40305295a3
diff --git a/data/chromelight/popup.js b/data/chromelight/popup.js
index 99472c3a6..9c4088ee4 100644
--- a/data/chromelight/popup.js
+++ b/data/chromelight/popup.js
@@ -225,7 +225,11 @@
function getFileExt(fileName) {
var ext = fileName.replace(/^.*?\.([a-zA-Z0-9]+)$/, "$1");
- return (ext.length === fileName.length) ? 'mhtml' : ext;
+ if (ext === "html" || ext === "htm" || ext.length === fileName.length) {
+ return 'mhtml'
+ } else {
+ return ext;
+ }
}
$(document).ready(init);