summaryrefslogtreecommitdiffstats
path: root/toolkit/content/contentAreaUtils.js
diff options
context:
space:
mode:
authorMatt A. Tobin <email@mattatobin.com>2020-02-01 23:45:36 -0500
committerMatt A. Tobin <email@mattatobin.com>2020-02-01 23:45:36 -0500
commit7d21d02d532fed5613501de63f8b3d50144a751f (patch)
tree06ae93efe12de8b25d207b13e81d8f6c2c0f2f7d /toolkit/content/contentAreaUtils.js
parenta18c27ddde9bb269948d5849df4840273237a24b (diff)
downloadUXP-7d21d02d532fed5613501de63f8b3d50144a751f.tar
UXP-7d21d02d532fed5613501de63f8b3d50144a751f.tar.gz
UXP-7d21d02d532fed5613501de63f8b3d50144a751f.tar.lz
UXP-7d21d02d532fed5613501de63f8b3d50144a751f.tar.xz
UXP-7d21d02d532fed5613501de63f8b3d50144a751f.zip
Issue #65 - Remove AppConstants from toolkit/content
Diffstat (limited to 'toolkit/content/contentAreaUtils.js')
-rw-r--r--toolkit/content/contentAreaUtils.js10
1 files changed, 4 insertions, 6 deletions
diff --git a/toolkit/content/contentAreaUtils.js b/toolkit/content/contentAreaUtils.js
index 736fb7dfc..2512804fa 100644
--- a/toolkit/content/contentAreaUtils.js
+++ b/toolkit/content/contentAreaUtils.js
@@ -24,8 +24,6 @@ XPCOMUtils.defineLazyModuleGetter(this, "Task",
"resource://gre/modules/Task.jsm");
XPCOMUtils.defineLazyModuleGetter(this, "Deprecated",
"resource://gre/modules/Deprecated.jsm");
-XPCOMUtils.defineLazyModuleGetter(this, "AppConstants",
- "resource://gre/modules/AppConstants.jsm");
XPCOMUtils.defineLazyModuleGetter(this, "NetUtil",
"resource://gre/modules/NetUtil.jsm");
@@ -1161,10 +1159,10 @@ function getNormalizedLeafName(aFile, aDefaultExtension)
if (!aDefaultExtension)
return aFile;
- if (AppConstants.platform == "win") {
- // Remove trailing dots and spaces on windows
- aFile = aFile.replace(/[\s.]+$/, "");
- }
+#ifdef XP_WIN
+ // Remove trailing dots and spaces on windows
+ aFile = aFile.replace(/[\s.]+$/, "");
+#endif
// Remove leading dots
aFile = aFile.replace(/^\.+/, "");