mercurial/extensions.py
changeset 33327 68b7ceda99d7
parent 33132 c467d13334ee
child 33526 792d121f22ba
--- a/mercurial/extensions.py	Fri Jul 07 00:12:44 2017 -0700
+++ b/mercurial/extensions.py	Fri Jul 07 00:13:53 2017 -0700
@@ -494,7 +494,11 @@
         if name in exts or name in _order or name == '__init__':
             continue
         exts[name] = path
-    exts.update(_disabledextensions)
+    for name, path in _disabledextensions.iteritems():
+        # If no path was provided for a disabled extension (e.g. "color=!"),
+        # don't replace the path we already found by the scan above.
+        if path:
+            exts[name] = path
     return exts
 
 def _moduledoc(file):