diff --git a/p/sncb/index.js b/p/sncb/index.js index 1756f538..3980a54e 100644 --- a/p/sncb/index.js +++ b/p/sncb/index.js @@ -11,13 +11,6 @@ import {parseLine} from '../../parse/line.js'; const baseProfile = require('./base.json'); import {products} from './products.js'; -// `www.belgianrail.be:443` doesn't provide the necessary CA certificate -// chain for Node.js to trust the certificate, so we manually add it. -// todo: fix this properly, e.g. by letting them know -const ca = readFileSync(new URL('./digicert-sha2-secure-server-ca.crt.pem', import.meta.url).pathname); -const agent = new Agent({ca}); -const transformReq = (ctx, req) => ({...req, agent}); - // todo: this is ugly const lineNameWithoutFahrtNr = ({parsed}) => { const {name, fahrtNr} = parsed; @@ -58,8 +51,6 @@ const profile = { locale: 'fr-BE', timezone: 'Europe/Brussels', - transformReq, - products, parseLine: parseHook(parseLine, lineNameWithoutFahrtNr),