mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 22:32:46 +00:00
Treat "https" the same as "http" for filename-determination purposes. Bug
263839 partial fix, patch by Phil <Time_lord@hotmail.com>, r=bzbarsky, sr=neil
This commit is contained in:
parent
b67ab5bad7
commit
c31b08b5c3
@ -433,8 +433,7 @@ function initFileInfo(aFI, aURL, aDocument, aContentType)
|
||||
// if saveURL(...) was the original caller (hence both aContentType and
|
||||
// aDocument are blank). If they were saving a link to a website then make
|
||||
// the extension .htm .
|
||||
if (!aFI.fileExt && !aDocument && !aContentType && (aURL.length > 7) &&
|
||||
aURL.substring(0,7).toUpperCase() == "HTTP://") {
|
||||
if (!aFI.fileExt && !aDocument && !aContentType && (/^http(s?):\/\//i.test(aURL))) {
|
||||
aFI.fileExt = "htm";
|
||||
aFI.fileBaseName = aFI.fileName;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user