diff --git a/lambda/mock/matchMock.js b/lambda/mock/matchMock.js index 94027802a6174e0bc0322a402c51d1ec51a53bd7..d74236126428dd543e48b76cbd9a1b3be1eec21a 100644 --- a/lambda/mock/matchMock.js +++ b/lambda/mock/matchMock.js @@ -14,7 +14,7 @@ function parseKey(key) { method = spliced[0].toLowerCase(); path = spliced[1]; // eslint-disable-line } - const routerBasePath = process.env.NODE_ENV === 'dev' ? `${path}` : `/.netlify/functions${path}`; + const routerBasePath = `${path}`; return { method, path: routerBasePath, diff --git a/netlify.toml b/netlify.toml index 5ecaa9640ddcfa44e69b09a66fda260740f87a3b..9d3438c4aff06f5a644d10167b5c7133f5175e45 100644 --- a/netlify.toml +++ b/netlify.toml @@ -3,7 +3,7 @@ [[redirects]] from = "/api/*" - to = "https://us-central1-antd-pro.cloudfunctions.net/api/api/:splat" + to = "/.netlify/functions/api/:splat" status = 200 force = true [redirects.headers]