about summary refs log tree commit diff stats
path: root/src/config
diff options
context:
space:
mode:
authorbptato <nincsnevem662@gmail.com>2023-12-14 14:33:28 +0100
committerbptato <nincsnevem662@gmail.com>2023-12-14 14:33:28 +0100
commit300944c355ce63efacf8f0a686fff8d6dcbb9e2c (patch)
tree1f3cef88902a7f31538de3ec71f984bef0843fe2 /src/config
parentae7cc86baff575bc6fa1d7e803858d54cbf69a8d (diff)
downloadchawan-300944c355ce63efacf8f0a686fff8d6dcbb9e2c.tar.gz
config: do not override user-defined urimethodmap
UMM resolution takes the first entry.
Diffstat (limited to 'src/config')
-rw-r--r--src/config/config.nim3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/config/config.nim b/src/config/config.nim
index 38ab6ffb..6500f73c 100644
--- a/src/config/config.nim
+++ b/src/config/config.nim
@@ -411,11 +411,12 @@ const DefaultURIMethodMap = parseURIMethodMap(staticRead"res/urimethodmap")
 
 proc getURIMethodMap*(config: Config): URIMethodMap =
   let configDir = getConfigDir() / "chawan" #TODO store this in config?
-  var urimethodmap = DefaultURIMethodMap
+  var urimethodmap: URIMethodMap
   for p in config.external.urimethodmap:
     let f = openFileExpand(configDir, p)
     if f != nil:
       urimethodmap.parseURIMethodMap(f.readAll())
+  urimethodmap.append(DefaultURIMethodMap)
   return urimethodmap
 
 proc getForkServerConfig*(config: Config): ForkServerConfig =