diff options
Diffstat (limited to 'src/local')
-rw-r--r-- | src/local/client.nim | 2 | ||||
-rw-r--r-- | src/local/pager.nim | 15 |
2 files changed, 1 insertions, 16 deletions
diff --git a/src/local/client.nim b/src/local/client.nim index 60bdf411..b59e1ef4 100644 --- a/src/local/client.nim +++ b/src/local/client.nim @@ -892,7 +892,7 @@ proc newClient*(config: Config; forkserver: ForkServer; jsctx: JSContext): let loader = forkserver.newFileLoader(LoaderConfig( urimethodmap: config.getURIMethodMap(), w3mCGICompat: config.external.w3m_cgi_compat, - cgiDir: pager.cgiDir, + cgiDir: seq[string](config.external.cgi_dir), tmpdir: config.external.tmpdir )) pager.setLoader(loader) diff --git a/src/local/pager.nim b/src/local/pager.nim index e5d7d062..f5dbff4b 100644 --- a/src/local/pager.nim +++ b/src/local/pager.nim @@ -104,7 +104,6 @@ type askcursor: int askpromise*: Promise[bool] askprompt: string - cgiDir*: seq[string] commandMode {.jsget.}: bool config*: Config connectingContainers*: seq[ConnectingContainerItem] @@ -277,13 +276,6 @@ proc quit*(pager: Pager, code = 0) = pager.term.quit() pager.dumpAlerts() -proc setPaths(pager: Pager): Err[string] = - var cgiDir: seq[string] - for path in pager.config.external.cgi_dir: - cgiDir.add(path) - pager.cgiDir = cgiDir - return ok() - proc newPager*(config: Config; forkserver: ForkServer; ctx: JSContext): Pager = let (mailcap, errs) = config.getMailcap() let pager = Pager( @@ -295,13 +287,6 @@ proc newPager*(config: Config; forkserver: ForkServer; ctx: JSContext): Pager = term: newTerminal(stdout, config), urimethodmap: config.getURIMethodMap() ) - let r = pager.setPaths() - if r.isErr: - pager.alert(r.error) - pager.alert("Exiting...") - #TODO maybe there is a better way to do this - pager.quit(1) - quit(1) for err in errs: pager.alert("Error reading mailcap: " & err) return pager |